Subject Re: [IBO] support for 2 transactions in ib_query
Author Helen Borrie
At 03:50 AM 1/07/2004 +0300, you wrote:
>This is my first post here. I'm evaluating IBO and Fibplus with firebird
>1.5 for building an erp solution.
>I've noticed that fibplus uses 2 transactions: 1 for the select (read) and
>another for update/insert/delete (write).
>Will IBO have this kind of functionality included in the near future?

IBO has always had multiple transactions - long before FIBPlus was born.

>I think this is a very useful feature because doing a commit on the write
>transaction won't invalidate the open cursor for the read transaction

It doesn't, anyway, even in the read-write context, if you use
CommitRetaining. CR is good for this; although one needs to ensure that a
hard commit occurs regularly (in terms of elapsed time) to avoid building
up garbage unnecessarily.

>and having the read transaction set to readonly will allow you to keep the
>transaction open for a long time without consuming too much resources on
>the server.

That is really the only advantage of this model, although a worthwhile one
for sites where different users are doing a lot of different tasks on a
wide range of data. However, it does separate the DML context from the
user's view. It's an imperfect model, therefore, for an environment with
many users where it's essential to miminise conflict and keep a real-time
view, as in a bookings system.

It's important to ensure that your read-only transaction has ReadCommitted
isolation level.