Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1aWNPB-0000y7-17 for pgsql-jdbc@arkaria.postgresql.org; Thu, 18 Feb 2016 12:09:57 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84) (envelope-from ) id 1aWNPA-0004Ow-Fj for pgsql-jdbc@arkaria.postgresql.org; Thu, 18 Feb 2016 12:09:56 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84) (envelope-from ) id 1aWNOf-0003rQ-VU for pgsql-jdbc@postgresql.org; Thu, 18 Feb 2016 12:09:26 +0000 Received: from smtp.procolix.com ([95.215.185.30]) by makus.postgresql.org with esmtp (Exim 4.84) (envelope-from ) id 1aWNOd-0004TH-2U for pgsql-jdbc@postgresql.org; Thu, 18 Feb 2016 12:09:24 +0000 Received: from localhost (localhost [127.0.0.1]) by smtp.procolix.com (Postfix) with ESMTP id 5D48343C5C for ; Thu, 18 Feb 2016 13:09:20 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at smtp.procolix.com Received: from smtp.procolix.com ([127.0.0.1]) by localhost (host436.procolix.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 8MEyWPK2BQA2 for ; Thu, 18 Feb 2016 13:09:18 +0100 (CET) Received: from webmail.procolix.com (webmail.procolix.com [95.215.185.106]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: mark@lawinegevaar.nl) by smtp.procolix.com (Postfix) with ESMTPSA id 64E2C43B26 for ; Thu, 18 Feb 2016 13:09:18 +0100 (CET) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Date: Thu, 18 Feb 2016 13:09:18 +0100 From: Mark Rotteveel To: Subject: Re: JDBC behaviour In-Reply-To: References: Message-ID: X-Sender: mark@lawinegevaar.nl User-Agent: RoundCube Webmail/0.2 X-Pg-Spam-Score: -1.9 (-) 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 On Thu, 18 Feb 2016 11:59:50 +0100 (CET), Andreas Joseph Krogh wrote: > På torsdag 18. februar 2016 kl. 11:43:36, skrev Sridhar N Bamandlapally < > sridhar.bn1@gmail.com >: > The code/framework is written to handle batch inserts, which is common for > all > databases  > I feel, PostgreSQL JDBC may need to modify setAutoCommit(false) code to > "implicit savepoint - on error - rollback to savepoint" > >   > You simply cannot have batch-inserts in the same transaction and expecting > the > batch not to fail if one of the statements in the batch fails. On a lot of other database systems, that is exactly how it works. If a statement fails, that one statement is backed out (rolled back), and it is still up to the user to decide if he wants to commit or rollback the statements that did succeed. Mark -- Sent via pgsql-jdbc mailing list (pgsql-jdbc@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-jdbc