|
|
| Think about Loose Coupling | |
| PerlMonks |
Re: Why does my insert work with DBI but fails with DBIx::Simple?by Tux (Prior) |
| on Feb 18, 2013 at 13:19 UTC ( #1019338=note: print w/ replies, xml ) | Need Help?? |
|
While your example might look harmless, are all the records like that? As in, do ALL the lines validate on splitting on ;? The example line has no quotation (or UTF-8 or embedded newlines), but once it does, reading your source like this is bound to lead to errors - somewhere. Use Text::CSV_XS or Text::CSV to parse CSV data. Better yet, if you are doing DBI anyway, why not use DBD::CSV to start with? Enjoy, Have FUN! H.Merijn
In Section
Seekers of Perl Wisdom
|
|
||||||||||||||||||||||