Update database using Java DSL JPA

2013-03-04 Thread golivamsi84
So can someone help me how I can update records in the database.Please explain me in detail if you can so that I can understand the flow. We are struggling on this one for a while now. thanks -- View this message in context: http://camel.465427.n5.nabble.com/Update-database-using-Java-DSL-JPA-

Re: Update database using Java DSL JPA

2013-03-04 Thread Claus Ibsen
that to update the entity. Then you can use java code to set the "flag". There is a little example from unti test here https://svn.apache.org/repos/asf/camel/trunk/components/camel-jpa/src/test/java/org/apache/camel/examples/MultiSteps.java > thanks > > > > -- > View this me

Re: Update database using Java DSL JPA

2013-03-04 Thread golivamsi84
message in context: http://camel.465427.n5.nabble.com/Update-database-using-Java-DSL-JPA-tp5728463p5728482.html Sent from the Camel - Users mailing list archive at Nabble.com.

Re: Update database using Java DSL JPA

2013-03-05 Thread Claus Ibsen
table A. > Yeah with JPA its possible easier to use the JPA API directly from a java bean and call that bean from a Camel route. If using SQL, MyBatis you can though just call the SQL that would do this update. > > > -- > View this message in context: > http://came

Re: Update database using Java DSL JPA

2013-03-05 Thread Baalu
in a route something like this: from(direct:input) .to(create an update query) .to(jpa:entity) Can we use a parametrized UPDATE query somehow to specify the columns and values to update? -- View this message in context: http://camel.465427.n5.nabble.com/Update-database-using-Java-DSL-JPA

Re: Update database using Java DSL JPA

2013-03-07 Thread Claus Ibsen
ntity) and then use the JPA API to merge / flush the changes. Though for the latter, you can also use the Camel JPA producer, eg to in a route .to("jpa:myEntityClassName") PS: Sometimes working with SQL is easier. > > > -- > View this message in context: > http://ca

Re: Update database using Java DSL JPA

2013-03-07 Thread Baalu
a criteria then take that value and update a column in Entity2. -- View this message in context: http://camel.465427.n5.nabble.com/Update-database-using-Java-DSL-JPA-tp5728463p5728776.html Sent from the Camel - Users mailing list archive at Nabble.com.