LINUX.IE, website of the Irish Linux Users' Group
Tux rules!

   
Home
New Users
Articles
Download
Projects
Community
Vendors

  Print Version
Email to...
 
Archives:


planetILUG

Recent News

News Archive


Join the
ILUG
on FaceBook


Join the
ILUG
on LinkedIn


Join the
ILUG SETI
Group



















 
 :: Mailing Lists

[ILUG] another solaris sort request

[ILUG] another solaris sort request

Sergiusz Paprzycki serek at walcz.net
Fri Jun 12 10:07:19 IST 2009


Pádraig Brady wrote:
> Hi,
> 
> Could someone with an [open]solaris system
> respond with the output from these commands?
> 
> printf "a 2\nb 1\n" | sort -n -k1.3,1.1
> printf "aa 2\nbb 1\n" | sort -n -k2.2,1.2
> 

Hi Pádraig,

Here yo go:

bash-3.00$ uname -a
SunOS octopus 5.10 Generic_118855-14 i86pc i386 i86pc
bash-3.00$ printf "a 2\nb 1\n" | sort -n -k1.3,1.1
a 2
b 1
bash-3.00$ printf "aa 2\nbb 1\n" | sort -n -k2.2,1.2
aa 2
bb 1

Hope it helps!

Regards,
Sergiusz

-- 
Sergiusz Paprzycki
M: +353 86 128 2483



More information about the ILUG mailing list
Read this without the formatting.
                                                                                                    

 

Hosted by HEAnet


Maintained by the ILUG website team. The aim of Linux.ie is to support and help commercial and private users of Linux in Ireland. You can display ILUG news in your own webpages, read backend information to find out how. Networking services kindly provided by HEAnet, server kindly donated by Dell. Linux is a trademark of Linus Torvalds, used with permission. No penguins were harmed in the production or maintenance of this highly praised website. Looking for the Indian Linux Users' Group? Try here. If you've read all this and aren't a lawyer: you should be!
RSS Version
Powered by Dell