Received: from fanthom.math.put.poznan.pl (root@fanthom.math.put.poznan.pl [150.254.5.54]) by hub.org (8.9.3/8.9.3) with ESMTP id GAA47757 for ; Sat, 22 May 1999 06:36:53 -0400 (EDT) (envelope-from kelman@fanthom.math.put.poznan.pl) Received: from pa131.poznan.ppp.tpnet.pl (pa131.poznan.ppp.tpnet.pl [212.160.10.131]) by fanthom.math.put.poznan.pl (8.8.7/8.8.7) with SMTP id MAA03515 for ; Sat, 22 May 1999 12:37:14 GMT Date: Sat, 22 May 1999 12:35:10 +0200 From: Piotr Stelmaszyk X-Mailer: The Bat! (v1.31) UNREG Reply-To: Piotr Stelmaszyk Organization: PUT X-Priority: 3 (Normal) Message-ID: <11524.990522@fanthom.math.put.poznan.pl> To: PgSQL-interfaces Subject: jdbc - number of updated rows Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Please tell me how to get to know how many rows has method executeUpdate affected. According to documentation Returns: either the row count for INSERT, UPDATE or DELETE ... this method should return number of updated rows, but it always returns 1. It's a feature(bug) of postgresql jdbc-driver? The only solution for my problem, that I made up is: turn off auto-commit select count(*) from table where tID=5 -- now i (probably)know number of updated rows update table set ... where tID=5 commit turn on auto-commit -- stupid, isn't it ... PS. remember that I'm new here... /--------------------------------------------------------/ /- Piotr Stelmaszyk |---- Student of Computer Science ---/ /------------------ | at Poznan University of Technology / /----- mailto:kelman@fanthom.math.put.poznan.pl ---------/ /----- mailto:kelman@alpha.net.pl -----------------------/ /--------------------------------------------------------/