1

Newbie here...

I'm working on a Spring MVC app and their JDBC api for data access. How would I go about saving data to multiple tables? The insertion needs to be such that if there's an error or something goes wrong, nothing gets inserted and rolled-back. Would this be Spring's transaction support? If so, the official documentation for transaction support is very confusing to me. Does anyone have a good source for learning how to do that?

I'm using Spring 3.1, Oracle 11g, and Tomcat 6.0

1 Answer 1

1

Yes, spring supports transaction. You can use DataSourceTransactionManager to configure your bean.IF you find xml mapping confusing you can use annotation @Transactional. Spring's annotation support for transactions are really simple. Spring in Action book has examples for transaction management.

Sign up to request clarification or add additional context in comments.

1 Comment

Thanks. I'm going to give a try (the book that is).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.