Thread: Error!

Error!

From
madan kulkarni
Date:

Dear all,

When i compile postgresql 7.2 with jakarta-ant 1.4.1 using the command,

./configure --with-java

, following errors were listed. Please help to solve this problem and please also specify the reasons for occurance of the errors.

compile:

[javac] Compiling 23 source files to /root/postgresql-7.2/src/interfaces/jdbc/build

[javac] /root/postgresql-7.2/src/interfaces/jdbc/org/postgresql/jdbc2/Statement.java:25: org.postgresql.jdbc2.Statement should be declared abstract; it does not define getMoreResults(int) in org.postgresql.jdbc2.Statement

[javac] public class Statement extends org.postgresql.Statement implements java.sql.Statement

[javac] ^

[javac] /root/postgresql-7.2/src/interfaces/jdbc/org/postgresql/jdbc2/PreparedStatement.java:32: org.postgresql.jdbc2.PreparedStatement should be declared abstract; it does not define setURL(int,java.net.URL) in org.postgresql.jdbc2.PreparedStatement

[javac] public class PreparedStatement extends Statement implements java.sql.PreparedStatement

[javac] ^

[javac] /root/postgresql-7.2/src/interfaces/jdbc/org/postgresql/jdbc2/CallableStatement.java:42: org.postgresql.jdbc2.CallableStatement should be declared abstract; it does not define registerOutParameter(java.lang.String,int) in org.postgresql.jdbc2.CallableStatement

[javac] public class CallableStatement extends org.postgresql.jdbc2.PreparedStatement implements java.sql.CallableStatement

[javac] ^

[javac] /root/postgresql-7.2/src/interfaces/jdbc/org/postgresql/jdbc2/Connection.java:37: org.postgresql.jdbc2.Connection should be declared abstract; it does not define setHoldability(int) in org.postgresql.jdbc2.Connection

[javac] public class Connection extends org.postgresql.Connection implements java.sql.Connection

[javac] ^

[javac] /root/postgresql-7.2/src/interfaces/jdbc/org/postgresql/jdbc2/DatabaseMetaData.java:40: org.postgresql.jdbc2.DatabaseMetaData should be declared abstract; it does not define supportsSavepoints() in org.postgresql.jdbc2.DatabaseMetaData

[javac] public class DatabaseMetaData implements java.sql.DatabaseMetaData

[javac] ^

[javac] /root/postgresql-7.2/src/interfaces/jdbc/org/postgresql/jdbc2/ResultSet.java:60: org.postgresql.jdbc2.ResultSet should be declared abstract; it does not define getURL(int) in org.postgresql.jdbc2.ResultSet

[javac] public class ResultSet extends org.postgresql.ResultSet implements java.sql.ResultSet

[javac] ^

[javac] /root/postgresql-7.2/src/interfaces/jdbc/org/postgresql/largeobject/PGblob.java:26: org.postgresql.largeobject.PGblob should be declared abstract; it does not define setBytes(long,byte[]) in org.postgresql.largeobject.PGblob

[javac] public class PGblob implements java.sql.Blob

[javac] ^

[javac] /root/postgresql-7.2/src/interfaces/jdbc/org/postgresql/largeobject/PGclob.java:26: org.postgresql.largeobject.PGclob should be declared abstract; it does not define setString(long,java.lang.String) in org.postgresql.largeobject.PGclob

[javac] public class PGclob implements java.sql.Clob

[javac] ^

[javac] /root/postgresql-7.2/src/interfaces/jdbc/org/postgresql/xa/ClientConnection.java:70: org.postgresql.xa.ClientConnection should be declared abstract; it does not define setHoldability(int) in org.postgresql.xa.ClientConnection

[javac] final class ClientConnection

[javac] ^

[javac] Note: Some input files use or override a deprecated API.

[javac] Note: Recompile with -deprecation for details.

[javac] 9 errors

BUILD FAILED

/root/postgresql-7.2/src/interfaces/jdbc/build.xml:72: Compile failed, messages should have been provided.

Total time: 16 seconds

Thankyou,

Madan kulkarni

 



Do You Yahoo!?
New! SBC Yahoo! Dial - 1st Month Free & unlimited access

Re: Error!

From
Dave Cramer
Date:
Madan,

The driver doesn't compile with jdk1.4 just download the jar from
jdbc.postgresql.org

Dave
On Sat, 2002-07-06 at 02:10, madan kulkarni wrote:
>
> Dear all,
>
> When i compile postgresql 7.2 with jakarta-ant 1.4.1 using the command,
>
> ./configure --with-java
>
> , following errors were listed. Please help to solve this problem and please also specify the reasons for occurance
ofthe errors. 
>
> compile:
>
> [javac] Compiling 23 source files to /root/postgresql-7.2/src/interfaces/jdbc/build
>
> [javac] /root/postgresql-7.2/src/interfaces/jdbc/org/postgresql/jdbc2/Statement.java:25:
org.postgresql.jdbc2.Statementshould be declared abstract; it does not define getMoreResults(int) in
org.postgresql.jdbc2.Statement
>
> [javac] public class Statement extends org.postgresql.Statement implements java.sql.Statement
>
> [javac] ^
>
> [javac] /root/postgresql-7.2/src/interfaces/jdbc/org/postgresql/jdbc2/PreparedStatement.java:32:
org.postgresql.jdbc2.PreparedStatementshould be declared abstract; it does not define setURL(int,java.net.URL) in
org.postgresql.jdbc2.PreparedStatement
>
> [javac] public class PreparedStatement extends Statement implements java.sql.PreparedStatement
>
> [javac] ^
>
> [javac] /root/postgresql-7.2/src/interfaces/jdbc/org/postgresql/jdbc2/CallableStatement.java:42:
org.postgresql.jdbc2.CallableStatementshould be declared abstract; it does not define
registerOutParameter(java.lang.String,int)in org.postgresql.jdbc2.CallableStatement 
>
> [javac] public class CallableStatement extends org.postgresql.jdbc2.PreparedStatement implements
java.sql.CallableStatement
>
> [javac] ^
>
> [javac] /root/postgresql-7.2/src/interfaces/jdbc/org/postgresql/jdbc2/Connection.java:37:
org.postgresql.jdbc2.Connectionshould be declared abstract; it does not define setHoldability(int) in
org.postgresql.jdbc2.Connection
>
> [javac] public class Connection extends org.postgresql.Connection implements java.sql.Connection
>
> [javac] ^
>
> [javac] /root/postgresql-7.2/src/interfaces/jdbc/org/postgresql/jdbc2/DatabaseMetaData.java:40:
org.postgresql.jdbc2.DatabaseMetaDatashould be declared abstract; it does not define supportsSavepoints() in
org.postgresql.jdbc2.DatabaseMetaData
>
> [javac] public class DatabaseMetaData implements java.sql.DatabaseMetaData
>
> [javac] ^
>
> [javac] /root/postgresql-7.2/src/interfaces/jdbc/org/postgresql/jdbc2/ResultSet.java:60:
org.postgresql.jdbc2.ResultSetshould be declared abstract; it does not define getURL(int) in
org.postgresql.jdbc2.ResultSet
>
> [javac] public class ResultSet extends org.postgresql.ResultSet implements java.sql.ResultSet
>
> [javac] ^
>
> [javac] /root/postgresql-7.2/src/interfaces/jdbc/org/postgresql/largeobject/PGblob.java:26:
org.postgresql.largeobject.PGblobshould be declared abstract; it does not define setBytes(long,byte[]) in
org.postgresql.largeobject.PGblob
>
> [javac] public class PGblob implements java.sql.Blob
>
> [javac] ^
>
> [javac] /root/postgresql-7.2/src/interfaces/jdbc/org/postgresql/largeobject/PGclob.java:26:
org.postgresql.largeobject.PGclobshould be declared abstract; it does not define setString(long,java.lang.String) in
org.postgresql.largeobject.PGclob
>
> [javac] public class PGclob implements java.sql.Clob
>
> [javac] ^
>
> [javac] /root/postgresql-7.2/src/interfaces/jdbc/org/postgresql/xa/ClientConnection.java:70:
org.postgresql.xa.ClientConnectionshould be declared abstract; it does not define setHoldability(int) in
org.postgresql.xa.ClientConnection
>
> [javac] final class ClientConnection
>
> [javac] ^
>
> [javac] Note: Some input files use or override a deprecated API.
>
> [javac] Note: Recompile with -deprecation for details.
>
> [javac] 9 errors
>
> BUILD FAILED
>
> /root/postgresql-7.2/src/interfaces/jdbc/build.xml:72: Compile failed, messages should have been provided.
>
> Total time: 16 seconds
>
> Thankyou,
>
> Madan kulkarni
>
>
>
>
>
> ---------------------------------
> Do You Yahoo!?
> New! SBC Yahoo! Dial - 1st Month Free & unlimited access






MetaData Bug

From
Aslak Hellesøy
Date:
Hi!

I finally got PostgreSQL running on my box to verify this metadata bug
myself. (It was mentioned yesterday).

My environment:

Win2k
Cygwin Setup.exe Version 2.249.2.5
PostgreSQL 7.2.1 on i686-pc-cygwin, compiled by GCC 2.95.3-5
PostgreSQL JDBC 7.3dev (built 2002-06-23) (devpgjdbc2.jar from
http://jdbc.postgresql.org/download.html).
j2sdk1.4.0_01

The bug appears for relationships involving more than one column. See the
definition of the VV and WW tables:
http://cvs.middlegen.sourceforge.net/cgi-bin/viewcvs.cgi/middlegen/middlegen
/src/sql/relations.sql?rev=1.1&content-type=text/vnd.viewcvs-markup

A call to DatabaseMetaData.getCrossReference(...) using these two tables
returns a resultset with one row. When I ask for the PKCOLUMN_NAME column of
that resultset I get "a,b". This is obviously wrong. The correct behaviour
would be to return a resultset with two rows, returning "a" the first time
and "b" the second time.

This can be observed by following these 11 steps:

--- GET AND BUILD MIDDLEGEN ---
0) Download Jakarta Ant 1.5.
1) Download Middlegen CVS version:
http://sourceforge.net/cvs/?group_id=36044
2) cd middlegen
3) ant

--- RUN THE MIDDLEGEN SAMPLE WITH POSTGRESQL ---
4) Edit line 17 in middlegen/samples/build.xml and replace hsqldb with
postgresql (don't worry about weblogic even if you don't have it).
5) Uncomment line 11 in middlegen/samples/build.properties.
6) Edit user/password info in
middlegen/samples/config/database/postgresql.xml at lines 25 and 26.
7) Edit line 31 in middlegen/samples/log4j.properties and set the debug
level to debug in stead of warn.
8) createdb airline (create a test database).
9) ant create-database (inserts test tables VV and WW and others in the
airline test database).
10) ant

This will fire up Middlegen which will connect to the database and read the
metadata - and throw an exception because of the bug described above.

I hope this is enough info for you to fix this little bug.

Cheers,
Aslak