Linux, programming, computers and life

March 9, 2009

sorting by certain columns in a file

Filed under: CLI, linux

I always knew that ’sort’ command has ‘-k N’ flag which tells to sort based on columns N,…. I just recently find out that this flag is even more versatile, and it can be used as ‘-k N,M’ which will sort based on columns N,…,M. As usuall, it’s in the man page, but i always missed it so far :) .

, ,

Get free blog up and running in minutes with Blogsome
Theme designed by Gary Rogers