Subject Re: [IBO] IBOQuery with record locking
Author earnesttse
Dear Jason Wharton,

Thanks for your quickly repy!

I don't need the second user to see changes from another user.

My problem is that when a user is editing a master/detail record
(edited and posted a row of detail table), if the second user read
this master/detail record, system will wait until the record has been
cancelled or posted.

In this case, if the first record of master/detail is editing,
another user can't open the query before the first user call commit
or rollback command.

Is there any way to allow another to read the old version of record
without waiting?

Thanks for help!

Earnest
--- In IBObjects@yahoogroups.com, "Jason Wharton" <supportlist@...>
wrote:
>
> It sounds like what you are asking for is a dirty read.
> This is not something that InterBase or Firebird allows.
> This is also something that is not desirable.
> If you want another user to be able to see changes from another
user then
> they have to be committed and in a tiCommitted isolation.
>
> Jason Wharton
>
> > -----Original Message-----
> > From: IBObjects@yahoogroups.com [mailto:IBObjects@yahoogroups.com]
On
> > Behalf Of earnesttse
> > Sent: Wednesday, March 19, 2008 7:01 PM
> > To: IBObjects@yahoogroups.com
> > Subject: [IBO] IBOQuery with record locking
> >
> >
> > Hello, I have a record locking problem needing your help!
> >
> > I have master/detail tables to record sale invoice. I call
> > IB_Database.StatTransaction before editing master reocrd. When one
> > user is editing a record of detial, other user can't read the
edited
> > record, system will wait until the record has been cancelled or
> > posted.
> >
> > Is there any way to allow the second user to view the edited
record
> > without waiting the first user completed editing?
> >
> > I read the book of Helen: The Firebird Book. I found that in page
> > 552: In Firebird, all updates are at row level ... When a
transaction
> > submits a request to update a row; the old version of that row
> > remains visible to all transactions. Writers do not block readers.
> >
> > Is there anything I missed?
> >
> > I am using Delphi 2007, IBO 4.8.7, IBOQuery, AutoCommit=True,
> > Isolation=tiCommitted.
> >
> > Your prompt reply is highly appreciated!
> > Thanks for help!
> >
> >
> > Earnest
>