Article View: borland.public.cppbuilder.database.ado
Article #2604Re: Level of transaction support
From: Edward Diener
Date: Tue, 22 Apr 2003 10:46
Date: Tue, 22 Apr 2003 10:46
38 lines
2735 bytes
2735 bytes
Kovalenko Dmitry wrote: > Hi > >> "Isolation Levels: has nothing to do with whether multiple >> transactions from a single connection are supported or, if they are, >> whether the multiple transaction is overlapped or nested. > > OK. > "Active Sessions" - The maximum number of session objects that can be > active at one time. Irrelevant to my question. > > Property with information about support nested transaction not > exists. You can analyse return code of StartTransaction: > > ITransactionLocal::StartTransaction when there is already an active > transaction on the session returns XACT_E_XTIONEXISTS. "XACT_E_XTIONEXISTS This session can handle only one extant transaction at a time, and there is presently such a transaction. The session supports a limited number of nested transactions, and that limit has been reached." This is good but after the fact. Also from VCL ADO implementation, the TADOConnection::BeginTrans() does not return the above information. As you say, there is unfortunately in ADO/OLEDB no way to determine the level of transaction support prior to calling a transaction. This is very poor design. Also it appears that there is no way to support overlapped transactions as opposed to either single transactions or nested transactions in ADO/OLEDB. Some databases, such as Interbase, support overlapped transactions and not nested transactions. If I call TADOConnection::BeginTrans() using Interbase and a transaction already exists in the connection, does BeginTrans() fail and throw an exception or does it succeed and return a value of 1 indicating a top-level transaction ? All in all, MS's documentation on transaction level support is very poor.
Technical Details
Message-ID:
<3ea51cce$1@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-03!sn-xit-01!sn-xit-08!supernews.com!newsfeed.wirehub.nl!news.kweb.on.ca!KWeb!newsgroups.borland.com!not-for-mailReferences:
<3ea2fb2b$1@newsgroups.borland.com> <1050902823.314958@sunflower.loc> <3ea45f3c$1@newsgroups.borland.com> <1050990899.658114@sunflower.loc>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 10698b,75bd37a927147926 X-Google-Attributes: gid10698b,public X-Google-ArrivalTime: 2003-04-22 03:52:19 PST From: "Edward Diener" <eddielee@tropicsoft.com> Newsgroups: borland.public.cppbuilder.database.ado References: <3ea2fb2b$1@newsgroups.borland.com> <1050902823.314958@sunflower.loc> <3ea45f3c$1@newsgroups.borland.com> <1050990899.658114@sunflower.loc> Subject: Re: Level of transaction support Date: Tue, 22 Apr 2003 06:46:19 -0400 Lines: 40 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2800.1106 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106 NNTP-Posting-Host: 66.245.13.153 Message-ID: <3ea51cce$1@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1051008206 66.245.13.153 (22 Apr 2003 03:43:26 -0700) Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-03!sn-xit-01!sn-xit-08!supernews.com!newsfeed.wirehub.nl!news.kweb.on.ca!KWeb!newsgroups.borland.com!not-for-mail