|
The code should be:
When you hit ," to start a quote string, don't look for another ,
Instead look for the ending "
Of course what happens when you have a " in the data, whatever
exported it should have escaped it in some manner. Usually by
doubling the "
Charles
On Fri, Oct 17, 2008 at 2:13 PM, Jeff Young <cooljeff913@xxxxxxxxx> wrote:
Does anyone have an example of how to extract a quoted string containinga comma in a CSV file?
I have adapted the PipeDelim program from Scott Kelment, and it worksgreat until I hit this condition.
I do not have the luxury of changing the format of the input file as itis being provided by a 3rd party.
V5R2
Thanks in advance,
Jeff Young
Sr. Programmer Analyst
IBM -e(logo) server Certified Systems Exper - iSeries Technical Solutions
IBM Certified Specialist- e(logo) server i5Series Technical SolutionsDesigner V5R3
IBM Certified Specialist- e(logo)server i5Series Technical SolutionsImplementer V5R3
--list
This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing
To post a message email: RPG400-L@xxxxxxxxxxxx--
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/rpg400-l.
This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing list
To post a message email: RPG400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/rpg400-l.
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.