On Fri, Oct 30, 2009 at 9:00 AM, DRy <[email protected]> wrote: > > Hi, > > > Claus Ibsen-2 wrote: >> >> >>> from("jpa:com.test.entity.Customer?consumer.namedQuery=findAll&delay=10000&consumeLockEntity=true&consumeDelete=true") >> >> See the unit tests of camel-jpa, for example JpaWithNamedQueryTest >> It could maybe inspire you. >> >> > > Sorry, but that didn't help at all ... > > I want to know how to pass a parameter for a namedQuery-based jpa consume in > something like that > > from("jpa:com.test.entity.Customer?consumer.namedQuery=findByOid) > > where findByOid is defined in my orm.ml > > <named-query name="findByOid"> > <query>SELECT c FROM Customer c WHERE c.oid = :oid</query> > </named-query> >
I dont think you can do it on the consumer side (eg in the from). Use a fixed value or do something else. Or create a ticket in JIRA so we can see how we can implemented this in camel. > > ... DRy > -- > View this message in context: > http://old.nabble.com/JPA%3A-How-to-pass-parameters-to-namedQuery-tp26118566p26126224.html > Sent from the Camel - Users mailing list archive at Nabble.com. > > -- Claus Ibsen Apache Camel Committer Author of Camel in Action: http://www.manning.com/ibsen/ Open Source Integration: http://fusesource.com Blog: http://davsclaus.blogspot.com/ Twitter: http://twitter.com/davsclaus
