Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id C31C74769A2 for ; Wed, 25 Sep 2002 16:38:04 -0400 (EDT) Received: from amer-mta02.csc.com (amer-mta02.csc.com [20.137.2.248]) by postgresql.org (Postfix) with ESMTP id A4BA94762FD for ; Wed, 25 Sep 2002 16:36:53 -0400 (EDT) Received: from amer-mta02.csc.com (localhost [127.0.0.1]) by amer-mta02.csc.com (Switch-2.2.2/Switch-2.2.0) with ESMTP id g8PKarj02211 for ; Wed, 25 Sep 2002 16:36:53 -0400 (EDT) Received: from csc.com (va-fch31.csc.com [20.6.39.231]) by amer-mta02.csc.com (Switch-2.2.2/Switch-2.2.0) with ESMTP id g8PKarj02186 for ; Wed, 25 Sep 2002 16:36:53 -0400 (EDT) Subject: Meaning of/ handling of ECPG_NOTICE_* ?? To: pgsql-interfaces@postgresql.org X-Mailer: Lotus Notes Release 5.0.6a January 17, 2001 Message-ID: From: "William West" Date: Wed, 25 Sep 2002 16:35:28 -0400 X-MIMETrack: Serialize by Router on VA-FCH31/SRV/CSC(Release 5.0.8 |June 18, 2001) at 09/25/2002 04:43:33 PM MIME-Version: 1.0 Content-type: text/plain; charset=us-ascii X-Virus-Scanned: by AMaViS new-20020517 X-Archive-Number: 200209/79 X-Sequence-Number: 3140 I have some ECPG based error recovery functions that can issue explicit BEGIN and ROLLBACK or COMMIT on a blind basis under some conditions. That is, BEGIN can sometimes be issued while already in a transaction, and ROLLBACK or COMMIT can sometimes be issued while not in a transaction. It seems that I sometimes get the resulting ECPG_NOTICE_[IN/NO]_TRANSACTION as the sqlca.sqlcode report in my *next* INSERT/ UPDATE/ SELECT/ FETCH, rather than in sqlca.sqlcode for the BEGIN/ ROLLBACK/COMMIT command? Is this possible? I am not doing anything on an asynchronous basis, at least not on purpose. If it *is* possible, how do I tell when the sqlca.sqlcode response for the INSERT/ UPDATE/SELECT/ FETCH command has arrived? What should I do with the NOTICE (apparently coming from the earlier BEGIN/ ROLLBACK/COMMIT) other than log it? [PostgreSQL 7.2.1 and ECPG 2.9.0, on RedHat 7.2, using Unix Domain connections exclusively]