in reply to CSV and regex mixups
CSV says that embedded quotes should be doubled in the CSV field. To see Text::CSV's notion of that,
It sounds as if your application is not producing valid CSV to that standard. See the CAVEATS section of the Text::CSV perldoc for the CSV convention the module is written to.$ perl -MText::CSV -e'$c = Text::CSV->new(); $c->combine qw/Crosby Stills Nash/, q/and sometimes "Young"/; print $c->string, $/' "Crosby","Stills","Nash","and sometimes ""Young""" $
Check Anydata::Format::CSV if you cannot get your data in Text::CSV's preferred format. It allows you to construct a parser with your choices for 'field_sep', 'quote', 'escape', and 'record_sep'. That may not fix all your problems if the app has a plain inadequate notion of CSV, but it might work.
After Compline,
Zaxo
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: CSV and regex mixups
by Tomte (Priest) on Jul 02, 2003 at 23:43 UTC |