You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by Paradies Thomas <th...@dmgmori.com> on 2017/09/14 06:14:12 UTC
Using Simple expressions in externalized sql queries?
Hi Camel users,
I have sql queries with named parameters in my application and use Simple expressions like :#${property.XXX} to access Exchange Properties. As long as I use this queries inlined, everything is fine. As soon as I externalize these queries as described in the component documentation, I get an error. When I use Headers instead of Properties and the :#XXX style again everything is fine.
Am I doing something wrong? Or, is that a problem with Camel?
BTW, I'm using Camel version 2.19.1.
Thanks,
Thomas
--
Follow us:
DECKEL MAHO Seebach GmbH
Sitz der Gesellschaft: Seebach (Wartburgkreis), Amtsgericht Jena, HRB 403305
Geschäftsführer: Dipl.-Ing. Hans-Günter Dose, Dipl.-Ing. Markus Rehm, Dipl.-Ing. (FH) Alfred Geißler
USt-ID-Nummer: DE 812185995, Finanzamt: Bielefeld-Außenstadt
RE: Using Simple expressions in externalized sql queries?
Posted by Paradies Thomas <th...@dmgmori.com>.
Hi Claus,
while putting together code fragments for the test case, I found the cause of the error...
It's that simple, changing
.enrich().simple("sql:{{select}}?dataSource=ds")
to
.enrich("sql:{{select}}?dataSource=ds"))
made it.
Sorry, my fault. Nevertheless, thank you.
Thomas
--
Follow us:
DECKEL MAHO Seebach GmbH
Sitz der Gesellschaft: Seebach (Wartburgkreis), Amtsgericht Jena, HRB 403305
Geschäftsführer: Dipl.-Ing. Hans-Günter Dose, Dipl.-Ing. Markus Rehm, Dipl.-Ing. (FH) Alfred Geißler
USt-ID-Nummer: DE 812185995, Finanzamt: Bielefeld-Außenstadt
-----Original Message-----
From: Claus Ibsen [mailto:claus.ibsen@gmail.com]
Sent: Thursday, September 14, 2017 8:59 AM
To: users@camel.apache.org
Subject: Re: Using Simple expressions in externalized sql queries?
Hi
Can you post the error and show a bit more of your code what you do
On Thu, Sep 14, 2017 at 8:14 AM, Paradies Thomas <th...@dmgmori.com> wrote:
> Hi Camel users,
>
> I have sql queries with named parameters in my application and use Simple expressions like :#${property.XXX} to access Exchange Properties. As long as I use this queries inlined, everything is fine. As soon as I externalize these queries as described in the component documentation, I get an error. When I use Headers instead of Properties and the :#XXX style again everything is fine.
>
> Am I doing something wrong? Or, is that a problem with Camel?
>
> BTW, I'm using Camel version 2.19.1.
>
> Thanks,
> Thomas
>
>
>
>
> --
> Follow us:
>
>
> DECKEL MAHO Seebach GmbH
> Sitz der Gesellschaft: Seebach (Wartburgkreis), Amtsgericht Jena, HRB
> 403305
> Geschäftsführer: Dipl.-Ing. Hans-Günter Dose, Dipl.-Ing. Markus Rehm,
> Dipl.-Ing. (FH) Alfred Geißler
> USt-ID-Nummer: DE 812185995, Finanzamt: Bielefeld-Außenstadt
>
>
--
Claus Ibsen
-----------------
http://davsclaus.com @davsclaus
Camel in Action 2: https://www.manning.com/ibsen2
Re: Using Simple expressions in externalized sql queries?
Posted by Claus Ibsen <cl...@gmail.com>.
Hi
Can you post the error and show a bit more of your code what you do
On Thu, Sep 14, 2017 at 8:14 AM, Paradies Thomas
<th...@dmgmori.com> wrote:
> Hi Camel users,
>
> I have sql queries with named parameters in my application and use Simple expressions like :#${property.XXX} to access Exchange Properties. As long as I use this queries inlined, everything is fine. As soon as I externalize these queries as described in the component documentation, I get an error. When I use Headers instead of Properties and the :#XXX style again everything is fine.
>
> Am I doing something wrong? Or, is that a problem with Camel?
>
> BTW, I'm using Camel version 2.19.1.
>
> Thanks,
> Thomas
>
>
>
>
> --
> Follow us:
>
>
> DECKEL MAHO Seebach GmbH
> Sitz der Gesellschaft: Seebach (Wartburgkreis), Amtsgericht Jena, HRB 403305
> Geschäftsführer: Dipl.-Ing. Hans-Günter Dose, Dipl.-Ing. Markus Rehm, Dipl.-Ing. (FH) Alfred Geißler
> USt-ID-Nummer: DE 812185995, Finanzamt: Bielefeld-Außenstadt
>
>
--
Claus Ibsen
-----------------
http://davsclaus.com @davsclaus
Camel in Action 2: https://www.manning.com/ibsen2