yerai
asked on
ora-29516 dont run main java in pl/sql
Hello,
i try to execute a java classes from pl/sql, how examples in manual, the VM is running in database is 10gr2 in windows xp and loadjava into database but and try to run present this error ora-29516 how the versions is not compatible the java code is:
public class EchoInput
{
public static void main (String args[])
{
System.out.println("hola") ;
}
}
and the procedure code is
CREATE OR REPLACE PROCEDURE echo_input AS
LANGUAGE JAVA NAME 'EchoInput.main (java.lang.String [])';
regards
i try to execute a java classes from pl/sql, how examples in manual, the VM is running in database is 10gr2 in windows xp and loadjava into database but and try to run present this error ora-29516 how the versions is not compatible the java code is:
public class EchoInput
{
public static void main (String args[])
{
System.out.println("hola")
}
}
and the procedure code is
CREATE OR REPLACE PROCEDURE echo_input AS
LANGUAGE JAVA NAME 'EchoInput.main (java.lang.String [])';
regards
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SELECT object_name, object_type, status
FROM user_objects WHERE object_type LIKE 'JAVA%';
what this query says (you run it in the schema where you created the java object)
FROM user_objects WHERE object_type LIKE 'JAVA%';
what this query says (you run it in the schema where you created the java object)
I believe that you cannot call a main method java from oracle.
>>public static void main (String args[])
It doesnt make sense.
Try to convert it to a method and load again.
>>public static void main (String args[])
It doesnt make sense.
Try to convert it to a method and load again.
the oracle 10.2 (assuming you have 10.2) has jdk 1.4.2
try to compile that class using jdk 1.4.2