Selecting awk output depending on grep result

view full story

http://www.unix.com – Hi, I don't script often enough to know how to do this, and I can't seem to find a right example online. I have a csv output from an old, old system (Win2K???), from which I want to extract only certain fields. Initially I came up with something like this: Code: cat file1 | awk -F '"' '{print $8 " " $12 " " $16}' The csv file contains some data like this: <file1> Code: "pippo","is fat","last","Cruise","first","Tom","UID","1234","more blah" "monky",& (HowTos)