File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Object Relational Mapping and the fly likes batch insert to different tables for one transaction Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Databases » Object Relational Mapping
Bookmark "batch insert to different tables for one transaction" Watch "batch insert to different tables for one transaction" New topic
Author

batch insert to different tables for one transaction

mihir maniar
Ranch Hand

Joined: Sep 09, 2003
Posts: 88
I would like to insert 3 records, 1 records each in 3 different tables to complete a transaction in IBATIS. I need to repeat this for about 3 to 4 lac records. So while using the SQLMAPExecutor object , while putting a different in this object resulted in taking a long time to insert 5000 records where as if I put only one insert query (i.e. inserting to one table only) then it would hardly 2 seconds to do the same. So please help me with this, since the transaction spans across 2 tables, i need to do that at once and then repeat the same for the other records. Thanks in advance.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: batch insert to different tables for one transaction
 
Similar Threads
How to display questions in several pages?
embedding a update & get in a ejb transaction
Common DAO layer Code Base - Hibernate Mapping XML changes
Uncommitted transaction state
Beginners question on EJB & transactions