applied Kris Jurka's patch for numeric
authorDave Cramer
Fri, 7 Feb 2003 12:47:29 +0000 (12:47 +0000)
committerDave Cramer
Fri, 7 Feb 2003 12:47:29 +0000 (12:47 +0000)
src/interfaces/jdbc/org/postgresql/jdbc1/AbstractJdbc1DatabaseMetaData.java

index 9e217f7f24fad0a153449584d2552b13cc0ec239..0d0ba7f00f5ff309fbbdc643aac083976af2a027 100644 (file)
@@ -2352,7 +2352,7 @@ public abstract class AbstractJdbc1DatabaseMetaData
            }
            else if (pgType.equals("numeric") || pgType.equals("decimal")) 
            {
-               int attypmod = rs.getInt(8) - VARHDRSZ;
+               int attypmod = rs.getInt("atttypmod") - VARHDRSZ;
                tuple[6] = Integer.toString( ( attypmod >> 16 ) & 0xffff ).getBytes();
                tuple[8] = Integer.toString(attypmod & 0xffff).getBytes();
                tuple[9] = "10".getBytes();