I resolve this problem by using Transactional Client.

<route>
    <from uri="direct:foo" />
    <transacted />
    <to uri="sql:INSERT INTO TEST_TBL (INSERT_DATE)
VALUES(NOW())?dataSource=dataSource" />
    <to uri="sql:SELECT LAST_INSERT_ID()?dataSource=dataSource" />
</route>

This route runs as expected so far.

if you tell me more efficient solution, I would appreciate.



--
View this message in context: 
http://camel.465427.n5.nabble.com/Use-same-db-connection-tp5779853p5779949.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Reply via email to