parsing issue with comma separated csv file

Posted by Andrei on Stack Overflow See other posts from Stack Overflow or by Andrei
Published on 2010-03-18T12:56:19Z Indexed on 2010/03/18 13:01 UTC
Read the original article Hit count: 393

Filed under:
|

I am trying to extract 4th column from csv file (comma separated, and skipping first 2 header lines) using this command,

 awk 'NR <2 {next}{FS =","}{print $4}' filename.csv | more

However, it doesn't work because the first column cantains comma, thus 4th column is not really 4th. Below is an example of a row:

"sdfsdfsd, sfsdf", 454,fgdfg, I_want_this_column,sdfgdg

© Stack Overflow or respective owner

Related posts about awk

Related posts about parsing