Re: Entity ejbRemove, with Foreign Key Dependancies, in a Transaction
Web Server forum
Back To The Forum Home!Search!Private Messaging System

Web Server Talk Web Server Talk > Web Servers reviews > WebSphere > WebSphere Application Server > Re: Entity ejbRemove, with Foreign Key Dependancies, in a Transaction




  Last Thread   Next Thread Next
  Show Printable Version Email this Page Subscribe to this Thread      Post New Thread    Post A Reply      

    Re: Entity ejbRemove, with Foreign Key Dependancies, in a Transaction  
Randy Schnier


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
09-20-05 11:06 PM

The problem has indeed come up before, and the "defer database updates
until end of transaction" mode is (intended to be) the solution.  With
that mode enabled, your DB remove operations will still occur in the
same transaction as the other operations, but will be performed last,
after your other operations to null out the references have been
processed.  Unless I'm misunderstanding your scenario (let me know if
that is the case), that should be what's needed to solve the problem.

Note, I'm assuming that your ejbRemove() method isn't performing any
database operations directly, which it shouldn't be when using
container-managed persistence.

c_koell wrote:
> Ok this could be a solution ..
> But has nobody had this problem before ?
>
> I want to remove from a client Table the foreign-Key relation from the Par
ent Table and in the same transaction
> delete the parent Table entry. A other solution for me could be to delete 
the parent table entry in a later transaction after the container has stored
 the client table entry with the new foreign key value.
>
> But then i lost the transaction atomic ..
>
> Maybe is there anybody out who had this problem to ??
> Thanks
> Claus
>





[ Post a follow-up to this message ]



    Sponsored Links  




 





   All times are GMT. The time now is 07:29 PM.      Post New Thread    Post A Reply      
  Last Thread   Next Thread Next


Most Popular forums 

Forum Jump:
Rate This Thread:

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are ON
[IMG] code is OFF
 
Medical and Health forum | Computer Games Reviews | Graphics design forum

Back To The Top
Home | Usercp | Faq | Register