Then use Entity beans and lock at that level, keith
------------------------------------------------------------------------- Keith Sterling MIAP Jacobs Rimell VP of Engineering Jacobs Rimell Ltd 24 Chiswell St London EC1Y 4TY Tel : +44 207 786 4000 Mob : +44 7771 597 630 Fax : +44 207 786 4004 Email : [EMAIL PROTECTED] MSN : [EMAIL PROTECTED] http://www.jacobsrimell.com ------------------------------------------------------------------------- IMPORTANT NOTICE: Unless posted by the originating sender to a public news group, this email should be considered confidential, may be legally privileged, and is for the intended recipient only. If you are not the intended recipient, please inform the sender and delete the email immediately. WARNING: It is impossible to guarantee the content of this message when it is delivered across the internet, therefore the sender accepts no liability for any claims arising from the information contained. > -----Original Message----- > From: Zahid Rahman [mailto:[EMAIL PROTECTED]] > Sent: 19 August 2002 02:17 > To: Keith Sterling > Cc: [EMAIL PROTECTED] > Subject: Re: Re: Problem Related to Isolation > > If you implement row level locking you would still lose performance > because in the parallel transaction(s) you would have to remember > to detect a deadlock. > > Once detected then you have to go for a retry > until you can achieve a successful commit or an irrevocable failure. > > The row level locking you have suggested I believe > is an oracle feature I *think*. > Not all databases allow row level locking as a rule. > > ----- Original Message ----- > From: "Keith Sterling" <[EMAIL PROTECTED]> > To: <c> > Sent: Monday, August 19, 2002 1:46 PM > Subject: Re: Problem Related to Isolation > > > > You have 2 methods for this. > > > > If you just want to stop some one else updating the row in the database, > > then use the "SELECT xxxx FOR UPDATE" SQL command, the addition of "FOR > > UPDATE" will cause the RDBMS to lock the row. > > > > However if you want to stop anyone accessing from the J2EE application, > then > > I would recommend implementing the access as an Entity Bean and then > using > > the J2EE server to implement Object Locking. I do this with Weblogic and > > once an object is fetched during a Transaction no other transaction can > get > > to it, until a .comitt() or .rollback(). > > > > You App Server should have documentation on how to configure object > locking, > > however this does slow performance down a fraction > > > > keith > > > > ------------------------------------------------------------------------ > - > > Keith Sterling MIAP > > Jacobs Rimell > > VP of Engineering > > Jacobs Rimell Ltd > > 24 Chiswell St > > London EC1Y 4TY > > Tel : +44 207 786 4000 > > Mob : +44 7771 597 630 > > Fax : +44 207 786 4004 > > Email : [EMAIL PROTECTED] > > MSN : [EMAIL PROTECTED] > > http://www.jacobsrimell.com > > ------------------------------------------------------------------------ > - > > IMPORTANT NOTICE: > > Unless posted by the originating sender to a public news group, this > email > > should be considered confidential, may be legally privileged, and is for > the > > intended recipient only. If you are not the intended recipient, please > > inform the sender and delete the email immediately. > > WARNING: > > It is impossible to guarantee the content of this message when it is > > delivered across the internet, therefore the sender accepts no > liability > > for any claims arising from the information contained. > > > > > > > > > -----Original Message----- > > > From: Pranav Shah [mailto:[EMAIL PROTECTED]] > > > Sent: 19 August 2002 13:27 > > > To: [EMAIL PROTECTED] > > > Subject: Problem Related to Isolation > > > > > > Hi All > > > I want my database row to be accesable from only one user. > > > I mean , when one user has accessed that row, no other user can > > > access that row. > > > > > > 1) how to do this ? if i am using Entity bean to fetch that row > > > from Database ? > > > 2) how to do this ? if i am using session bean to fetch that row > > > from Database ? > > > > > > let me know u r views > > > > > > Thanks in Advance > > > > > > Pranav > > > > > > > > > > > > Thanks > > > Pranav Shah > > > Software Engineer > > > http://www.pranav.itgo.com > > > > > > > ========================================================================== > > > = > > > To unsubscribe, send email to [EMAIL PROTECTED] and include in the > > > body > > > of the message "signoff EJB-INTEREST". For general help, send email > to > > > [EMAIL PROTECTED] and include in the body of the message "help". > > > > > ========================================================================== > = > > To unsubscribe, send email to [EMAIL PROTECTED] and include in the > body > > of the message "signoff EJB-INTEREST". For general help, send email to > > [EMAIL PROTECTED] and include in the body of the message "help". > > =========================================================================== To unsubscribe, send email to [EMAIL PROTECTED] and include in the body of the message "signoff EJB-INTEREST". For general help, send email to [EMAIL PROTECTED] and include in the body of the message "help".
