Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1buzZZ-0003DR-Rc for pgsql-jdbc@arkaria.postgresql.org; Fri, 14 Oct 2016 10:18:41 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1buzZZ-0003kd-9Z for pgsql-jdbc@arkaria.postgresql.org; Fri, 14 Oct 2016 10:18:41 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1buzZY-0003kS-PS for pgsql-jdbc@postgresql.org; Fri, 14 Oct 2016 10:18:40 +0000 Received: from mx1.redhat.com ([209.132.183.28]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1buzZM-0003PI-TV for pgsql-jdbc@postgresql.org; Fri, 14 Oct 2016 10:18:40 +0000 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 1C91A6198E for ; Fri, 14 Oct 2016 10:18:26 +0000 (UTC) Received: from [10.36.116.82] (ovpn-116-82.ams2.redhat.com [10.36.116.82]) by int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id u9EAIOIY013488 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Fri, 14 Oct 2016 06:18:25 -0400 Subject: Re: Return Codes of BatchUpdateException in PostgreSql 9.6 To: pgsql-jdbc@postgresql.org References: <63578883.319462.1476435530742.ref@mail.yahoo.com> <63578883.319462.1476435530742@mail.yahoo.com> From: Jeremy Whiting Message-ID: <64d5a53b-97a4-6e96-03af-2ab818bfa4cd@redhat.com> Date: Fri, 14 Oct 2016 11:18:24 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.2.0 MIME-Version: 1.0 In-Reply-To: <63578883.319462.1476435530742@mail.yahoo.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.68 on 10.5.11.22 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.38]); Fri, 14 Oct 2016 10:18:26 +0000 (UTC) X-Pg-Spam-Score: -7.3 (-------) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-jdbc Precedence: bulk Sender: pgsql-jdbc-owner@postgresql.org Hi, Comments in-line.... On 14/10/16 09:58, Tillmann Schulz wrote: > Hello, > > I made some test with different driver versions. The result seems to be that it is an issue in the newer driver versions and not in the postgresql database > > > Postgres 9.5.0 with postgresql-jdbc41-9.4-1201.jar contains only updateCounts of first succeeded statements. > > --------------------------------------------------------------------------------------------------------------- > > updateCounts[0]=1 > updateCounts[1]=1 > updateCounts[2]=1 > updateCounts[3]=1 > updateCounts[4]=1 > -->correct The value 1 is the batched statement return code for j.s.Statement.SUCCESS_NO_INFO > > > Postgres 9.6.0 with postgresql-jdbc41-9.4-1201.jar contains only updateCounts of first succeeded statements. > --------------------------------------------------------------------------------------------------------------- > updateCounts[0]=1 > updateCounts[1]=1 > updateCounts[2]=1 > updateCounts[3]=1 > updateCounts[4]=1 > -->correct but can't use this driver with postgressql 9.6 > See above. > > Postgres 9.6.0 with postgresql-jdbc41-9.4-1211.jar contains updateCounts of all elements. > > --------------------------------------------------------------------------------------------------------------- > updateCounts[0]=-3 > updateCounts[1]=-3 > updateCounts[2]=-3 > updateCounts[3]=-3 > updateCounts[4]=-3 > updateCounts[5]=-3 > updateCounts[6]=-3 > updateCounts[7]=-3 > updateCounts[8]=-3 > updateCounts[9]=-3 > -->Wrong.updateCounts[0..4] and updateCounts[6..9] contains wrong information. > > > >> will need to set logLevel=2 > How can I set the logLevel. Is it in postgresql.conf? logLevel is a connection property. With that enabled you can expect to see lots of low level protocol logging. Exposing driver (FE) to back end (BE) and responses (BE -> FE). It is the BE->FE that is helpful in this case. Regards, Jeremy > > Bye, > > Tillmann > > -- Sent via pgsql-jdbc mailing list (pgsql-jdbc@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-jdbc