Hello.

I use a blueprint XML format. This is the "end" of my route : the
first part just extracts properties from a SOAP or any external
interface requests and routes them to this "direct:" path to write the
data to my DB...

<route id="TestCase-DB-Insert">
        <from uri="direct:db-insert" />
        <setBody>
                <simple>
                        INSERT INTO demand (
                                requester_name,
                                requester_mail,
                                demand,
                                agent,
                                status,
                                correlation
                        ) VALUES (
                                '${property.inputRequesterName}',
                                '${property.inputRequesterMail}',
                                '${property.inputDemand}',
                                '${property.inputAgent}',
                                0,
                                '${exchangeId}'
                        )
                </simple>
        </setBody>
        <log
                logName="{{my.logger.ws}}"
                loggingLevel="DEBUG"
                message="Case insert SQL = ${body}" />
        <to uri="jdbc:my.ds" />
</route>

As the properties are directly written into the query statement, any
special character may break its syntax...

An idea, or comment about my case ?

Thanks. Regards


On Tue, Aug 14, 2012 at 6:02 PM, Jean-Baptiste Onofré [via ServiceMix]
<[email protected]> wrote:
> Hi,
>
> could you share your Camel route definition ?
> Which DSL do you use ?
>
> Thanks,
> Regards
> JB
>
> On 08/13/2012 10:00 AM, Ephemeris Lappis wrote:
>
>> Hello.
>>
>> I've found no way to escape characters in the query text to execute SQL
>> using the JDBC component. For example, the *apostrophe* character in text
>> values breaks the statement query and produces errors...
>>
>> Any idea ?
>>
>> Thanks.
>> Regards.
>>
>>
>>
>> --
>> View this message in context:
>> http://servicemix.396122.n5.nabble.com/Camel-JDBC-and-escaping-characters-tp5714136.html
>> Sent from the ServiceMix - User mailing list archive at Nabble.com.
>>
>
> --
> Jean-Baptiste Onofré
> [hidden email]
> http://blog.nanthrax.net
> Talend - http://www.talend.com
>
>
> ________________________________
> If you reply to this email, your message will be added to the discussion
> below:
> http://servicemix.396122.n5.nabble.com/Camel-JDBC-and-escaping-characters-tp5714136p5714149.html
> To unsubscribe from Camel JDBC and escaping characters, click here.
> NAML




--
View this message in context: 
http://servicemix.396122.n5.nabble.com/Camel-JDBC-and-escaping-characters-tp5714136p5714151.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.

Reply via email to