Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. gborrageiro

    awk: print colums $1 through to $5

    hi, Is there a simple way to cat a file a print colums 1 through to 5? This is how I tediously accomplish this at the moment: cat file | awk '{print $1$2$3$4$5}' would be great to use a range of some sort, eg: cat file | awk '{print $1:$5}' many thanks
  2. gborrageiro

    Print minimum value in column

    hello, I'm having trouble printing the minimum numerical value in a column. When I try printing the maximum value it works fine. It's almost as if awk does'nt like the '<' parameter. The command I run is: cat file | awk '$5 < min {min=$5; minline=$0}; END{ print min, minline}' The result is...

Part and Inventory Search

Back
Top