From: Kris Jurka Date: Mon, 13 Sep 2004 07:14:26 +0000 (+0000) Subject: ResultSet.moveToCurrentRow was checking the cached updateability flag X-Git-Tag: REL7_4_6~18 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=5e8046cbc94ca20672b8d1d8dc30d56dcfdbd7ba;p=thirdparty%2Fpostgresql.git ResultSet.moveToCurrentRow was checking the cached updateability flag assuming it had been set instead of correctly calling the isUpdateable() method which sets the flag if needed. This usually worked because moveToCurrentRow is only useful after a moveToInsertRow call which would set the flag, but this is not required. David Bucciarelli --- diff --git a/src/interfaces/jdbc/org/postgresql/jdbc2/AbstractJdbc2ResultSet.java b/src/interfaces/jdbc/org/postgresql/jdbc2/AbstractJdbc2ResultSet.java index 2667a373b43..263524f2fd1 100644 --- a/src/interfaces/jdbc/org/postgresql/jdbc2/AbstractJdbc2ResultSet.java +++ b/src/interfaces/jdbc/org/postgresql/jdbc2/AbstractJdbc2ResultSet.java @@ -9,7 +9,7 @@ * Copyright (c) 2003, PostgreSQL Global Development Group * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/interfaces/jdbc/org/postgresql/jdbc2/Attic/AbstractJdbc2ResultSet.java,v 1.25.2.8 2004/06/21 03:11:49 jurka Exp $ + * $Header: /cvsroot/pgsql/src/interfaces/jdbc/org/postgresql/jdbc2/Attic/AbstractJdbc2ResultSet.java,v 1.25.2.9 2004/09/13 07:14:26 jurka Exp $ * *------------------------------------------------------------------------- */ @@ -692,7 +692,7 @@ public abstract class AbstractJdbc2ResultSet extends org.postgresql.jdbc1.Abstra public synchronized void moveToCurrentRow() throws SQLException { - if (!updateable) + if (!isUpdateable()) { throw new PSQLException( "postgresql.updateable.notupdateable" ); }