This week's book giveaway is in the Kotlin forum.
We're giving away four copies of Kotlin in Action and have Dmitry Jemerov & Svetlana Isakova on-line!
See this thread for details.
Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Transaction attributes  RSS feed

 
Suma GS
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have a method say X()in session bean and the transaction attribute set to it is "requires new". X() calls create method of an entity method which inserts a record into a master table. After inserting a record, method X() calls findByXXX() method of child table. When this statement is excecuted, I get an Exception saying "TransactionRolledback..... SQL Exception... parent key not found.."
Any help on this?
Thanks
Suma
 
David Harrigan
Ranch Hand
Posts: 43
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hmm, possible error in creating the "parent" record.
This may be of help:
http://www.coderanch.com/t/308423/EJB-JEE/java/Transaction-Attributes-EJB
-=david=-
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!