Quotes in quoted strings

Discussion on developing CloverETL engine, transformation components etc.

ericl
Posts: 5
Joined: Thu Mar 28, 2013 9:07 pm

Quotes in quoted strings

Postby ericl » Thu Sep 12, 2013 8:31 pm

Hi,

I'm currently just using the CloverETL java data parser (no graph) to parse some data files. The version we are using is 3.3.1.

One problem that we are facing is handling the quotes within a quoted string (ex: "Michael "Mike" O'Neil") where the quote character is " (double quote) and the quotedString attribute is set to true. This throw a

Code: Select all

java.lang.RuntimeException: Parsing error: Bad quote format
.

I know that the problem was already reported here:

http://forum.cloveretl.com/viewtopic.php?f=4&t=528&p=1602&hilit=double+quote+in+quoted+string#p1602

But I was wondering if it has been fixed (ex: by using an escape character like the '\' and hence have something like "Michael \"Mike\" O'Neil").

Is there a plan to use an escape character for quotes within quotes in future releases ? It seems to be something that could happen quite often.

Thanks,
Eric

mkrivanek
Posts: 11
Joined: Tue Nov 08, 2011 4:25 pm

Re: Quotes in quoted strings

Postby mkrivanek » Tue Sep 24, 2013 3:57 pm

Hi Eric,

Please double the quote character for escaping:

Code: Select all

"Michael ""Mike"" O'Neil"
Milan Krivanek
CloverCARE Support
CloverETL | Rapid Data Integration

Visit us online at http://www.cloveretl.com

ericl
Posts: 5
Joined: Thu Mar 28, 2013 9:07 pm

Re: Quotes in quoted strings

Postby ericl » Mon Sep 30, 2013 6:42 pm

That worked!

Thank you Milan!

Eric


cron