http://qs321.pair.com?node_id=99386


in reply to Delete unmatched quotes from a delimited file?

I guess you can count the number of quotes and add one if it's missing. This assumes you can't quote pipes. Something like this might do:

while ( <> ) { my @F = split /\|/; foreach ( @F ) { $_ .= '"' if tr/"// & 1; } print join '|', @F; }

--bwana147