Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1WSmJq-0002s5-VK for pgsql-hackers@arkaria.postgresql.org; Wed, 26 Mar 2014 11:48:31 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1WSmJq-0008Sj-FC for pgsql-hackers@arkaria.postgresql.org; Wed, 26 Mar 2014 11:48:30 +0000 Received: from makus.postgresql.org ([2001:4800:7903:4::125]) by malur.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1WSmJp-0008Sb-1B for pgsql-hackers@postgresql.org; Wed, 26 Mar 2014 11:48:29 +0000 Received: from sd.tpf.co.jp ([210.161.239.34]) by makus.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1WSmJl-0005zc-JV for pgsql-hackers@postgresql.org; Wed, 26 Mar 2014 11:48:28 +0000 Received: (qmail 11050 invoked by uid 512); 26 Mar 2014 11:48:22 -0000 X-Authentication: inoue was authenticated by sd.tpf.co.jp at 26 Mar 2014 11:48:22 -0000 Received: from unknown (HELO ?192.168.1.4?) (183.76.63.174) by sd.tpf.co.jp with SMTP; 26 Mar 2014 11:48:22 -0000 Message-ID: <5332BE84.4040309@tpf.co.jp> Date: Wed, 26 Mar 2014 20:48:20 +0900 From: Hiroshi Inoue User-Agent: Mozilla/5.0 (Windows NT 6.0; rv:24.0) Gecko/20100101 Thunderbird/24.4.0 MIME-Version: 1.0 To: Michael Paquier , PostgreSQL mailing lists Subject: Re: New parameter RollbackError to control rollback behavior on error References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Pg-Spam-Score: -2.3 (--) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-hackers Precedence: bulk Sender: pgsql-hackers-owner@postgresql.org Hi Michael, Isn't it an ODBC issue? regards, Hiroshi Inoue (2014/03/26 15:39), Michael Paquier wrote: > Hi all, > > The behavior of rollback when an error occurs on an handle is > controlled by extending Protocol with "$PROTNUM-[0|1|2]" where: > - 0 = let the application handle rollbacks > - 1 = rollback whole transaction when an error occurs > - 2 = rollback only statement that failed > Using such an extension is somewhat awkward as a single string is used > for two settings... The proposed attached patch adds a new parameter > called RollbackError that allows to control the behavior of rollback > on error with a different parameter. > > For backward-compatibility purposes, this patch does not break the old > grammar of Protocol: it just gives the priority to RollbackError if > both Protocol and RollbackError are set for a connection. Regression > tests to test RollbackError and combinations of RollbackError/Protocol > are added in the patch in the existing test error-rollback (which has > needed some refactoring, older tests are not impacted). Docs are > included as well. > > I thought first about including that in my cleanup work for 9.4, but > as this actually does not break the driver it may be worth adding it > directly to master, explaining the patch attached here. Comments > welcome. Note that if there are objections I do not mind adding that > for the work that would be merged later to 9.4 builds. > > Regards, -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers