Skip site navigation (1) Skip section navigation (2)

Re: Batch Update problem

From: Kris Jurka <books(at)ejurka(dot)com>
To: Hadraba Petr <hadrabap(at)bluetone(dot)cz>
Cc: pgsql-jdbc(at)postgresql(dot)org
Subject: Re: Batch Update problem
Date: 2008-01-07 02:55:52
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-jdbc

On Sun, 30 Dec 2007, Hadraba Petr wrote:

> I have a global PreparedStatement pStmt that handles the UPDATE
> statement.
> In for-cycle I'm doing the following:
>  - prepare values for the UPDATE
>  - call pStmt.clearParameters();
>  - call pStmt.setObject(paramOrderID, paramValue) for each value with
> the right paramID and value
>  - call pStmt.addbatch();
> After the for-cycle I'm calling the pStmt.executeBatch(); and
> pStmt.close();
> Please note, no Exceptions are thrown — the SQL code is correct and no 
> primary key nor foreign key valoations are occuring.
> I'm able to post full source code and more info.

Please post a full test case.  I don't see any reason why Jdbc3 vs Jdbc3g 
would be any different.

Kris Jurka

In response to


pgsql-jdbc by date

Next:From: Kris JurkaDate: 2008-01-07 03:03:58
Subject: Re: Check constraint metadata
Previous:From: Kris JurkaDate: 2008-01-07 02:52:12
Subject: Re: Missing fields in getColumns() result

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group