Article View: borland.public.cppbuilder.database.ado
Article #1391Using transactions
From: Dan
Date: Fri, 02 Jul 2004 15:50
Date: Fri, 02 Jul 2004 15:50
23 lines
1283 bytes
1283 bytes
HI all,
iam using zeos access component wich, works a litle like the ADO component (at least thats what i heard). In ZConnection i have methods like StartTransaction(), Commit(),Rollback() i think i have to do something like
try
{
ZConnection1->StartTransaction();
ZQuery1->insert...
...
...
.-.
}catch (?!?!?)
{
ZConnection1->RollBack();
}
else
{
ZConnection1->Commit();
}
but i dont know how to get the error from the DB (iam using postgres)
Thx in advanced
Technical Details
Message-ID:
<40e58440$1@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!fu-berlin.de!newsfeed.iinet.net.au!newsfeed.iinet.net.au!PeerFeed.KWeb.on.ca!news.kweb.on.ca!newsgroups.borland.com!not-for-mailShow Full Headers
Complete Article Headers
X-Google-Thread: 10698b,c0adafe1332eb6a2,start X-Google-Attributes: gid10698b,public X-Google-Language: ENGLISH,ASCII-7-bit From: "Dan " <danferro@portugalmail.pt> Sender: "Dan " <danferro@portugalmail.pt> Reply-To: "Dan " <danferro@portugalmail.pt> Subject: Using transactions Newsgroups: borland.public.cppbuilder.database.ado X-User-Info: 195.23.20.134 X-Forwarded-For: 10.230.7.98 NNTP-Posting-Host: 207.105.83.66 Message-ID: <40e58440$1@newsgroups.borland.com> Date: 2 Jul 2004 08:50:24 -0700 X-Trace: newsgroups.borland.com 1088783424 207.105.83.66 (2 Jul 2004 08:50:24 -0700) Lines: 23 Path: arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!fu-berlin.de!newsfeed.iinet.net.au!newsfeed.iinet.net.au!PeerFeed.KWeb.on.ca!news.kweb.on.ca!newsgroups.borland.com!not-for-mail