Bash: Parse CSV with quotes, commas and newlines
问题 Say I have the following csv file: id,message,time 123,"Sorry, This message has commas and newlines",2016-03-28T20:26:39 456,"It makes the problem non-trivial",2016-03-28T20:26:41 I want to write a bash command that will return only the time column. i.e. time 2016-03-28T20:26:39 2016-03-28T20:26:41 What is the most straight forward way to do this? You can assume the availability of standard unix utils such as awk, gawk, cut, grep, etc. Note the presence of "" which escape , and newline