Thanks for your reply Claus.
My fisrt try was with this method :
from("direct:create")
.setHeader("dataSource", simple("myDynamicDataSource"))
.to(simple("sql:insert into customer(firstname, lastname)
values(:#firstName, :#lastName)?dataSource=#${header.dataSource}")
.getText()).to("log:output");
Bu when the camel constext is started I have the following error:
Caused by: org.apache.camel.NoSuchBeanException: No bean could be found in
the registry for: ${header.dataSource} of type: javax.sql.DataSource
Arnaud
--
View this message in context:
http://camel.465427.n5.nabble.com/Dynamic-DataSource-tp5771402p5771427.html
Sent from the Camel - Users mailing list archive at Nabble.com.