Problem With Java Stored Procedure invoking Windows runtime process [message #555246] |
Tue, 22 May 2012 11:38 |
|
p_pml
Messages: 15 Registered: February 2012
|
Junior Member |
|
|
Hello,
I am trying to invoke program from my local Windows machine (exactly java executor, which is in my environment on c:\java\jdk\bin\java) using database package with Java stored procedure.
Everything is fired by SQLPLUS script, this script invokes package with Java stored procedure (jar loaded into Oracle) and that procedure is trying to invoke runtime process (syntax: c:\java\jdk\bin\java -cp and here arae my classes and main jar) using my local java executor. I added all permissions using dbms_java.grant_permisions (execution forced me to give permissions java.io.FilePermission to <<ALL_FILES>> for execute), moreover I added to my database user JAVASYSPRIV and JAVAUSERPRIV role. Unfortunately, beside this I am still getingg error: C:\java\jdk\bin\java not found (Note that lookup with PATH isn't done due to the oracle executable being setuid.)
I have no idea what can I do more, every advice would be very helpful.
|
|
|
|
|
|
|
|
Re: Problem With Java Stored Procedure invoking Windows runtime process [message #555274 is a reply to message #555248] |
Tue, 22 May 2012 16:46 |
ThomasG
Messages: 3212 Registered: April 2005 Location: Heilbronn, Germany
|
Senior Member |
|
|
You seem to be mixing up a few concepts.
* You can call anything on the server from inside a PL/SQL procedure. PL/SQL runs on the server, there is no way to run something on the client. (unless you can run "remote commands" via SSH or some other remote access on the client from the server)
* You could call a OS process on the client from the SQL script run by SQL*Plus, but NOT from inside a PL/SQL process that runs ON THE SERVER.
|
|
|
|
|