Error creating PL/SQL wrapper PLS-00311: ... declaration ... malformed
55677Aug 22 2003 — edited Aug 22 2003Hello all,
I have successfully created a java program as per my last question, and although I can run it just fine in JDeveloper, and I can load it into Oracle without errors with loadjava, I cannot get the wrapper to work.
We'll use the code I plagiarized to get started (SAXNameSpace) as an example, as I get exactly the same error with it.
http://spdoc.cineca.it/oracle8i/appdev.817/a86030/adx17p10.htm
I paste it into a new workspace in Jdeveloper (9i) and make one modification (making the main method just call my new "main" (parsexml), hoping that I can just call parsexml through PL/SQL):
static public void main(String[] args)
{
parsexml(args);
}
static public void parsexml(String[] args) {
It compiles fine.
I load it into the database...
Oracle8i Enterprise Edition Release 8.1.7.0.0 - Production
With the Partitioning option
JServer Release 8.1.7.0.0 - Production
... with this command:
loadjava -user username/password@devel -oci8 -resolve C:\Install\jdev903\jdev\mywork\Workspace2\Project1\src\mypackage1\SAXNamespace.java
The load works without a hitch and I can now see the source and the class in user_objects, both with a status of VALID.
Then I try to create a wrapper for it:
CREATE OR REPLACE procedure java_test_jh as
language java name 'mypackage1.SAXNamespace.parsexml(java.lang.String[] args)';
/
...and I get this error:
PLS-00311: the declaration of "mypackage1.SAXNamespace.parsexml(java.lang.String[] args)" is incomplete or malformed
Can someone please help me? I've spent hours on this project, (I'm a PL/SQL programmer by trade), I have a working model of what I need to do and I'm so close I can taste it!