Subject Re: [IBO] IBO - Long time opened Query
Author Lester Caine
> I have a small question: suppose that there is a TIB_Query opened after
> application start and stays opened until the application is closed. This can
> last several hours. The TIB_Query is opened in TIB_Transaction with
> AutoCommit=true.
>
> Question is: in multiuser environment, can this approach have substantial
> impact on Firebird performance and resources, especially if there are aprox.
> 10-20 of such queries in every application?

See your first post <g>

IF records are being edited and so transactions being held
open, then there is a problem. IBO tries where possible to
close transactions, but using pessimistic locking does not
help that action. In normal operation then, as long as there
are no updated records that have not been commited, then
there is not a problem.

I 'lock records' by setting a status flag and commiting that
change rather than relying on pessimistic locking. The flag
can then be checked in any triggers, and operations
controlled - outside of a blocked transaction. That may not
be prectical for you, but works for me, and allows accurate
control of who is updating a record ( the flag is a user
number <g> ). This is not used often, as I normally edit
'offline' and flag any changes when trying to post the update.

--
Lester Caine
-----------------------------
L.S.Caine Electronic Services