Subject | Re: Two Fase Commit |
---|---|
Author | Alexander V.Nevsky |
Post date | 2004-07-09T18:11:46Z |
--- In firebird-support@yahoogroups.com, "Horacio Jamilis"
<hjamilis@y...> wrote:
IBX only and it is simply. Let's say you have connections IBDataBase1
and IBDataBase2 and transaction IBTransaction1. For example,
IBDataBase1.Connected:=True;
IBDataBase2.Connected:=True;
IBTransaction1.AddDataBase(IBDataBase1);
IBTransaction1.AddDataBase(IBDataBase2);
IBTransaction1.StartTransaction;
now you can perform queries which Transaction property is set to
IBTransaction1 for both databases. When you'll commit IBTransaction1,
it will be commited in both databases, the same with rollback. If
connection with one of the databases will be lost before
commit/rollback, transaction in both databases will be marked "in
limbo" and you should rollback it manually using gfix tool.
Best regards,
Alexander.
<hjamilis@y...> wrote:
> Hi,fase transaction.
>
> Can someone send me a code (or metacode) sample of the use of two
> If the sample is in delphi code, better.Horacio, it depends on components which you use. I can explain for
IBX only and it is simply. Let's say you have connections IBDataBase1
and IBDataBase2 and transaction IBTransaction1. For example,
IBDataBase1.Connected:=True;
IBDataBase2.Connected:=True;
IBTransaction1.AddDataBase(IBDataBase1);
IBTransaction1.AddDataBase(IBDataBase2);
IBTransaction1.StartTransaction;
now you can perform queries which Transaction property is set to
IBTransaction1 for both databases. When you'll commit IBTransaction1,
it will be commited in both databases, the same with rollback. If
connection with one of the databases will be lost before
commit/rollback, transaction in both databases will be marked "in
limbo" and you should rollback it manually using gfix tool.
Best regards,
Alexander.