Page 1 of 1

TIBCConnection.TransactionCount

Posted: Wed 04 Mar 2015 18:45
by martinlara
Hi,

I expose the next case:

I have a component TIBCConnection (IBCConn) and two components TIBCTransaction (IBCTranA and IBCTranB). The default transaction is IBCTranA.

Now, began the application, I inspect the property TIBCConnection.TransactionCount and I obtain as result 4. So I walk the transactions and I find that 2 of them have names and 2 do not, well:

IBCConn.Transactions[0].Name = ''
IBCConn.Transactions[1].Name = ''
IBCConn.Transactions[2].Name = 'IBCTranA'
IBCConn.Transactions[3].Name = 'IBCTranB'

Why the transactions 1 and 2?

Thanks!

Re: TIBCConnection.TransactionCount

Posted: Thu 05 Mar 2015 10:46
by ViktorV
InterBase/Firebird requires an active transaction for any operation with data. Therefore, when creating a TIBCConnection instance, internal transactions are created, that are used if you don't specify any particular transaction.