-
ORA-29532: Java call
terminated by uncaught Java exception:
string
-
-
Cause: A Java
exception or error was signaled and could not be resolved by
the Java code.
-
-
Action: Modify Java code, if this behavior is not intended.
Oracle forums have
published suggestions offering
descriptions of problems regarding ORA-29532. These
suggestions outline
these error possibilities and resolutions by showing three examples.
Perhaps one of these examples is similar to your problem with
ORA-29532:
Sometimes an application
running in the Oracle JVM
will fail with a java permissions error having the
following format:
(Note: Message shown below have been reformatted for easier
readability.)
java.sql.SQLException: ORA-29532:Java call terminated by
uncaught Java exception:
followed by a detailed error message similar to one of the
following messages:
-----------
Example # 1
-----------
java.security.AccessControlException: the Permission
(java.net.SocketPermission hostname resolve)
has not been granted by dbms_java.grant_permission to
SchemaProtectionDomain(SCOTT|PolicyTableProxy(SCOTT))
-----------
Example # 2
-----------
java.security.AccessControlException: the Permission
(java.util.PropertyPermission * read,write)
has not been granted by dbms_java.grant_permission to
SchemaProtectionDomain(SCOTT|PolicyTableProxy(SCOTT))
-----------
Example # 3
-----------
java.security.AccessControlException: the Permission
(java.io.FilePermission \matt1.gif read)
has not been granted by dbms_java.grant_permission to
SchemaProtectionDomain(SCOTT|PolicyTableProxy(SCOTT))
The reason ORA-29532 occurs is
because "The java 2 permission stated in line # 2 of each of the
above "Examples"
has not been granted to the user specified in line 4 of the above
"Examples"." To resolve ORA-29532:
The methodology to solve this
issue is identical for all java 2 permissions
cases.
1) Format a call "dbms_java.grant_permission" procedure
as described below.
2) Logon as SYS or SYSTEM
3) Issue the TWO commands shown below
4) Logoff as SYS or SYSTEM
5) Retry your application
---------------
For Example # 1
---------------
1) Logon as SYS or SYSTEM
2) Issue the following commands :
a) call dbms_java.grant_permission('SCOTT',
'java.net.SocketPermission',
'hostname',
'resolve');
b) commit;
Note: Commit is mandatory !!
3) Logoff as SYS or SYSTEM
4) Retry your application
---------------
For Example # 2
---------------
1) Logon as SYS or SYSTEM
2) Issue the following commands :
a) call dbms_java.grant_permission('SCOTT',
'java.util.PropertyPermission',
'*',
'read,write');
b) commit;
Note: Commit is mandatory !!
3) Logoff as SYS or SYSTEM
4) Retry your application
---------------
For Example # 3
---------------
1) Logon as SYS or SYSTEM
2) Issue the following commands :
a) call dbms_java.grant_permission('SCOTT',
'java.io.FilePermission',
'\matt1.gif',
'read');
b) commit;
Note: Commit is mandatory !!
3) Logoff as SYS or SYSTEM
4) Retry your application