[Pljava-dev] Class not found error

Peter Henderson peter.henderson at starjar.com
Tue Aug 8 11:28:56 UTC 2006


The power of posting to a mailing list.

About 30 seconds after I hit send, a solution appears.

I needed to set the class path on the schema, to make the functions
available.

SELECT sqlj.set_classpath('javatest', 'samples');

http://wiki.tada.se/wiki/display/pljava/Sample+Tests
http://wiki.tada.se/wiki/display/pljava/set_classpath




Peter Henderson wrote:
> I've just installed PL/Java 1.3 on postgresql 8
> 
> The installation appeared to work well.
> 
> But whenever I try to call any Java function (including the samples) I
> get a Class not found exception
> 
> 
> select * from javatest.print('Hello');
> 
> ERROR:  java.lang.ClassNotFoundException:
> org.postgresql.pljava.example.Parameters
> 
> 
> 
> Yet the tables in the sqlj schema indicate the examples jar file was
> loaded ok.
> 
> starjarpartech20060421=# select entryname from sqlj.jar_entry;
>                                entryname
> ------------------------------------------------------------------------
>  org/postgresql/pljava/example/SetOfRecordTest.class
>  org/postgresql/pljava/example/ComplexTuple.class
>  org/postgresql/pljava/example/Threads.class
>  org/postgresql/pljava/example/ResultSetTest.class
>  org/postgresql/pljava/example/ComplexScalar.class
>  org/postgresql/pljava/example/Threads$Locker.class
>  org/postgresql/pljava/example/RandomInts.class
>  org/postgresql/pljava/example/Parameters.class
>  org/postgresql/pljava/example/SPIActions$1.class
>  org/postgresql/pljava/example/HugeResultSet.class
>  org/postgresql/pljava/example/Users.class
>  org/postgresql/pljava/example/MetaDataStrings$1MethodComparator.class
>  org/postgresql/pljava/example/BinaryColumnTest.class
>  org/postgresql/pljava/example/UsingPropertiesAsResultSet.class
>  org/postgresql/pljava/example/AnyTest.class
>  org/postgresql/pljava/example/Point.class
>  org/postgresql/pljava/example/MetaDataBooleans.class
>  org/postgresql/pljava/example/MetaDataInts$1MethodComparator.class
>  org/postgresql/pljava/example/TupleReturn.class
>  org/postgresql/pljava/example/MetaDataStrings.class
>  org/postgresql/pljava/example/UsingPropertiesAsScalarSet.class
>  org/postgresql/pljava/example/SPIActions.class
>  org/postgresql/pljava/example/MetaDataInts.class
>  org/postgresql/pljava/example/MetaDataBooleans$1MethodComparator.class
>  org/postgresql/pljava/example/Security.class
>  org/postgresql/pljava/example/LoggerTest.class
>  org/postgresql/pljava/example/UsingProperties.class
>  org/postgresql/pljava/example/MetaDataTest.class
>  org/postgresql/pljava/example/Triggers.class
>  .timestamp
>  deployment/examples.ddr
>  org/postgresql/pljava/example/example.properties
>  com/starjar/crm/postgres/BomList.class
> (33 rows)
> 
> 
> 
> What have i missed?
> 
> 
> Peter Henderson
> 
> _______________________________________________
> Pljava-dev mailing list
> Pljava-dev at gborg.postgresql.org
> http://gborg.postgresql.org/mailman/listinfo/pljava-dev
> 




More information about the Pljava-dev mailing list