Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Transaction Attribute  RSS feed

 
Tmmet Johnson
Ranch Hand
Posts: 56
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I have the below questions in transaction attribute.Can anyone mail me the answers.
1. In my stateless sessionbean methods, I use delete sql queries to delete records from the database.
My question is "Can I set the transaction attribute to NotSupported for the above bean methods?". what about for multiple delete sql queries in the same bean method?

2. In my stateless sessionbean methods, I just use multiple select sql queries to fetch records from the database.
My question is "Can I set the transaction attribute to Supports for the above bean methods?"

I have asked question 2 in my previous post for single sql query.
Just want to make sure the same is applicable for multiple sql queries.

Thanks in advance,
 
Shrinivas Mujumdar
Ranch Hand
Posts: 328
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It depends on how you want to handle the situation & it is much more design issue as comapred to sql queries you are using.
so its difficult to tell you from queries(single/multiple)try to understand the effect of Transaction Attributes from some good resource(O'reilly EJB Book/Head First EJB)

I hope this helps,
feel free to throw a question if you are not satisfied
Shrinivas
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!