It is simple to parse each row with a regular expression.
You don't say in what form you want to store the data, but this short program may help.
I have use Data::Dump
to display the contents of the @data
array after processing the file.
use strict;
use warnings;
my @data;
while (<DATA>) {
my @fields = /"([^"]*)"/g;
push @data, \@fields;
}
use Data::Dump;
dd \@data;
__DATA__
["ABC","D EF","XYZ"]
["MNO","P","QR ST"]
["A"]
output
[["ABC", "D EF", "XYZ"], ["MNO", "P", "QR ST"], ["A"]]