X-Original-To: pgsql-interfaces-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 23C39D1B1CE for ; Wed, 7 Jul 2004 13:31:59 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 96761-07 for ; Wed, 7 Jul 2004 16:31:54 +0000 (GMT) Received: from esri3.esri.com (dwp.esri.com [198.102.62.250]) by svr1.postgresql.org (Postfix) with ESMTP id 25BA0D1B20E for ; Wed, 7 Jul 2004 13:31:52 -0300 (ADT) Received: from zipwire.esri.com (zipwire.esri.com [46.1.2.224]) by esri3.esri.com (8.11.6+Sun/8.11.6) with ESMTP id i67GVoM20818 for ; Wed, 7 Jul 2004 09:31:50 -0700 (PDT) Received: by zipwire.esri.com with Internet Mail Service (5.5.2657.72) id ; Wed, 7 Jul 2004 09:28:49 -0700 Message-ID: <491DC5F3D279CD4EB4B157DDD62237F404E27F00@zipwire.esri.com> From: Brijesh Shrivastav To: PostgreSQL Interfaces Subject: Re: Libpq and transactions Date: Wed, 7 Jul 2004 09:28:47 -0700 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2657.72) Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200407/16 X-Sequence-Number: 5022 Thanks for clarification! I got confused with document wording. Brijesh Shrivastav -----Original Message----- From: Tomasz Myrta [mailto:jasiek@klaster.net] Sent: Wednesday, July 07, 2004 12:05 AM To: Brijesh Shrivastav Cc: PostgreSQL Interfaces Subject: Re: [INTERFACES] Libpq and transactions On 2004-07-07 01:50, U=C5=BCytkownik Brijesh Shrivastav napisa=C5=82: > Hi!=20 >=20 > I have a question about how transaction behaves in libpq library. > It is very clear in doc that PQexec treats each command (which could=20 > comprise of more than one sql command) as a single transactions.=20 Not exactly. PQexec treats each command as a single transaction only=20 when you don't add "begin" before your query. If you add "begin" before=20 first query - it will finish after "commit" or "rollback". Regards, Tomasz Myrta ---------------------------(end of broadcast)--------------------------- TIP 5: Have you checked our extensive FAQ? http://www.postgresql.org/docs/faqs/FAQ.html