Using AWK to parse CSV files
First, GNU AWK.
gawk 'BEGIN { FPAT = "([^,]*)|(\"[^\"]+\")" }
{ for (i = 1; i <= NF; i++) {
if (substr($i, 1, 1) == "\"") {
len = length($i)
$i = substr($i, 2, len - 2)
}
}
print $2 //do what you need here
}'
See https://www.gnu.org/software/gawk/manual/html_node/Splitting-By-Content.html for more information