diff options
author | Bruce Momjian <bruce@momjian.us> | 2001-08-22 13:20:06 +0000 |
---|---|---|
committer | Bruce Momjian <bruce@momjian.us> | 2001-08-22 13:20:06 +0000 |
commit | ef80c87f60b7377728f9eb0005b0af22f9afcb48 (patch) | |
tree | 1ec7683d0e1b80d4484fe1ce30efb5eca26202ca /src/interfaces/jdbc | |
parent | e8f7bfc09526a5ba25a9f9b4ae9ce8509f6ceced (diff) | |
download | postgresql-ef80c87f60b7377728f9eb0005b0af22f9afcb48.tar.gz postgresql-ef80c87f60b7377728f9eb0005b0af22f9afcb48.zip |
Attached is a simple one line patch for the problem reported in the
following email.
> > The problem: When I call getBigDecimal() on a ResultSet, it
> > sometimes throws an exception:
> >
> > Bad BigDecimal 174.50
> > at org.postgresql.jdbc2.ResultSet.getBigDecimal(ResultSet.java:373)
> > at org.postgresql.jdbc2.ResultSet.getBigDecimal(ResultSet.java:984)
> > ...blah blah blah...
> > org.postgresql.util.PSQLException: Bad BigDecimal 174.50
Barry Lind
Diffstat (limited to 'src/interfaces/jdbc')
-rw-r--r-- | src/interfaces/jdbc/org/postgresql/jdbc2/ResultSet.java | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/interfaces/jdbc/org/postgresql/jdbc2/ResultSet.java b/src/interfaces/jdbc/org/postgresql/jdbc2/ResultSet.java index 6ff3b60a745..ad81a7c61fc 100644 --- a/src/interfaces/jdbc/org/postgresql/jdbc2/ResultSet.java +++ b/src/interfaces/jdbc/org/postgresql/jdbc2/ResultSet.java @@ -798,8 +798,7 @@ public class ResultSet extends org.postgresql.ResultSet implements java.sql.Resu public java.math.BigDecimal getBigDecimal(int columnIndex) throws SQLException { - // Now must call BigDecimal with a scale otherwise JBuilder barfs - return getBigDecimal(columnIndex,0); + return getBigDecimal(columnIndex,-1); } public java.math.BigDecimal getBigDecimal(String columnName) throws SQLException |