postgresql-jdbc.git / summary / log / commit / refs
commit b33732def06f4e03005f3e2ac9033a72fd680798
Author: Kris Jurka <books@ejurka.com>
Date: Fri Dec 01 10:27:05 2006 +0000
New fast int/long retrieval methods were not correctly setting the
wasNullFlag, so future calls to ResultSet.wasNull would not return
the correct value.
org/postgresql/jdbc2/AbstractJdbc2ResultSet.java | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/org/postgresql/jdbc2/AbstractJdbc2ResultSet.java b/org/postgresql/jdbc2/AbstractJdbc2ResultSet.java
index 7f1a275a..0c0d506f 100644
--- a/org/postgresql/jdbc2/AbstractJdbc2ResultSet.java
+++ b/org/postgresql/jdbc2/AbstractJdbc2ResultSet.java
@@ -3,7 +3,7 @@
* Copyright (c) 2003-2005, PostgreSQL Global Development Group
*
* IDENTIFICATION
-* $PostgreSQL: pgjdbc/org/postgresql/jdbc2/AbstractJdbc2ResultSet.java,v 1.86 2006/11/05 05:58:22 jurka Exp $
+* $PostgreSQL: pgjdbc/org/postgresql/jdbc2/AbstractJdbc2ResultSet.java,v 1.87 2006/11/05 07:45:16 jurka Exp $
*
*-------------------------------------------------------------------------
*/
@@ -1999,7 +1999,8 @@ public abstract class AbstractJdbc2ResultSet implements BaseResultSet, org.postg
checkResultSet( columnIndex );
columnIndex--;
- if (this_row[columnIndex] == null) {
+ wasNullFlag = (this_row[columnIndex] == null);
+ if (wasNullFlag) {
return 0; // SQL NULL
}
@@ -2057,7 +2058,8 @@ public abstract class AbstractJdbc2ResultSet implements BaseResultSet, org.postg
checkResultSet( columnIndex );
columnIndex--;
- if (this_row[columnIndex] == null) {
+ wasNullFlag = (this_row[columnIndex] == null);
+ if (wasNullFlag) {
return 0; // SQL NULL
}
[parent: dedda5e6fd5a]