JDBC: java.lang.ArrayIndexOutOfBoundsException: 256

From: Mirko Zeibig <mirko(at)picard(dot)inka(dot)de>
To: pgsql-general(at)postgresql(dot)org
Subject: JDBC: java.lang.ArrayIndexOutOfBoundsException: 256
Date: 2001-01-24 14:43:38
Message-ID: 20010124154338.A22257@picard.inka.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general pgsql-jdbc

Hello,
my system:
RedHat 7.0
postgresql 7.1 (CVS)
IBMJava2-SDK-1.3-1.1

After having set JAVA_HOME "ant" is working like a charm, now it will build
postgresql.jar and postgresql-example.jar. I noticed however that there is a
difference between the ant and the make built: whereas with ant the jar has
about 83kB, with "make jdbc2" it is about 180kB

If I now switch to src/interfaces/jdbc/jars and execute:

java -cp postgresql.jar:postgresql-examples.jar example.psql \
jdbc:postgresql:mirko mirko *****

or alternatively from src/interfaces/jdbc

java -cp postgresql.jar:jars/postgresql-examples.jar example.psql \
jdbc:postgresql:mirko mirko *****

I always get the following error:
[mirko(at)romulan jdbc]$ java -cp
postgresql.jar:postgresql-examples.jar example.psql
jdbc:postgresql:mirko mirko mirko
PostgreSQL psql example v6.3 rev 1

Connecting to Database URL = jdbc:postgresql:mirko
Exception caught.
Something unusual has occured to cause the driver to fail. Please report
this exception: java.lang.ArrayIndexOutOfBoundsException: 256
Something unusual has occured to cause the driver to fail. Please report
this exception: java.lang.ArrayIndexOutOfBoundsException: 256
at java.lang.Throwable.<init>(Throwable.java:84)
at java.lang.Exception.<init>(Exception.java:35)
at java.sql.SQLException.<init>(SQLException.java:100)
at org.postgresql.util.PSQLException.<init>(PSQLException.java:42)
at org.postgresql.Driver.connect(Driver.java:127)
at java.sql.DriverManager.getConnection(DriverManager.java:523)
at java.sql.DriverManager.getConnection(DriverManager.java:183)
at example.psql.<init>(psql.java:31)
at example.psql.main(psql.java:207)

PostgreSQL is accessible by unix-sockets and tcp/ip, I have no problems
connecting via psql, python or php.

I read the source of Driver.connect as well and found a description to
connect via jdbc:org.postgresql:mirko, which did result in a driver not
found error.

TIA

Mirko

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Bruce Momjian 2001-01-24 14:45:02 Re: [GENERAL] User names
Previous Message Dave Cramer 2001-01-24 14:37:49 VACUUM ANALYZE FAILS on 7.0.3

Browse pgsql-jdbc by date

  From Date Subject
Next Message Bruce Momjian 2001-01-24 14:56:36 Re: [INTERFACES] BIT type still not working
Previous Message Bruce Momjian 2001-01-24 14:22:53 Re: no way in LargeObject API to detect short read?