Win a copy of Java 9 Revealed this week in the Features new in Java 9 forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Rollback issue with Hibernate in JBoss  RSS feed

 
Ian Link
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Lets say i have 100 rows to insert and the 100th item has an error (eg a value to big for column). When the commit is executed an exception is thrown and rollback is called. However, the first 99 records are still being persisted to the database and not being rolledback.

I am using an oracle database and running in a JBoss 4.0.2 container using an MBean managed SessionFactory and jboss transaction manager

The code looks like this:

 
Consider Paul's rocket mass heater.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!