|
8 | 8 | import org.postgresql.largeobject.*;
|
9 | 9 | import org.postgresql.util.*;
|
10 | 10 |
|
11 |
| -/* $Header: /cvsroot/pgsql/src/interfaces/jdbc/org/postgresql/jdbc1/Attic/AbstractJdbc1Statement.java,v 1.15 2003/02/04 09:20:08 barry Exp $ |
| 11 | +/* $Header: /cvsroot/pgsql/src/interfaces/jdbc/org/postgresql/jdbc1/Attic/AbstractJdbc1Statement.java,v 1.16 2003/02/04 10:09:32 barry Exp $ |
12 | 12 | * This class defines methods of the jdbc1 specification. This class is
|
13 | 13 | * extended by org.postgresql.jdbc2.AbstractJdbc2Statement which adds the jdbc2
|
14 | 14 | * methods. The real Statement class (for jdbc1) is org.postgresql.jdbc1.Jdbc1Statement
|
@@ -1890,18 +1890,21 @@ public Object getObject(int parameterIndex)
|
1890 | 1890 | */
|
1891 | 1891 | public String toString()
|
1892 | 1892 | {
|
| 1893 | + if (m_sqlFragments == null) |
| 1894 | + return ""; |
| 1895 | + |
1893 | 1896 | synchronized (sbuf)
|
1894 | 1897 | {
|
1895 | 1898 | sbuf.setLength(0);
|
1896 | 1899 | int i;
|
1897 | 1900 |
|
1898 | 1901 | for (i = 0 ; i < m_binds.length ; ++i)
|
1899 | 1902 | {
|
| 1903 | + sbuf.append (m_sqlFragments[i]); |
1900 | 1904 | if (m_binds[i] == null)
|
1901 | 1905 | sbuf.append( '?' );
|
1902 | 1906 | else
|
1903 |
| - sbuf.append (m_sqlFragments[i]); |
1904 |
| - sbuf.append (m_binds[i]); |
| 1907 | + sbuf.append (m_binds[i]); |
1905 | 1908 | }
|
1906 | 1909 | sbuf.append(m_sqlFragments[m_binds.length]);
|
1907 | 1910 | return sbuf.toString();
|
@@ -2070,7 +2073,7 @@ public boolean isUseServerPrepare()
|
2070 | 2073 | private static final String PG_INT8 = "int8";
|
2071 | 2074 | private static final String PG_NUMERIC = "numeric";
|
2072 | 2075 | private static final String PG_FLOAT = "float";
|
2073 |
| - private static final String PG_DOUBLE = "double"; |
| 2076 | + private static final String PG_DOUBLE = "double precision"; |
2074 | 2077 | private static final String PG_BOOLEAN = "boolean";
|
2075 | 2078 | private static final String PG_DATE = "date";
|
2076 | 2079 | private static final String PG_TIME = "time";
|
|
0 commit comments