Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: Java Stored Procedure Requirements

Re: Java Stored Procedure Requirements

From: Vladimir M. Zakharychev <bob_at_dpsp-yes.com>
Date: Tue, 26 Nov 2002 12:04:18 +0300
Message-ID: <arvdis$por$1@babylon.agtel.net>


> well, I still think, my way also works.

Unlikely.

>
> Jane, I don't know what you want to do exactly, but
> if you are using a language which supports exception-handling
> (like PL/SQL, Java, Delphi, ...),
> just do this:
>
> Pseudocode
>
> try
> blablabla // invoke Java Stored procedure on server
> exception // find out which exception to catch
> when Java_Stored_procedure_on_server_is_not_supported then
> error('Java Stored procedure on server is not supported');
> end;

The question was not if one can call a Java SP, but what are the prerequisites to be able to *create* one. Your approach will not work as you first have to create Java SP and only then you can try to call it - and if your Oracle instance is not Java-enabled, then you will fail on create step and will never come to trying that procedure. Avi gave correct answer to the original question, though there also is another way to verify if Oracle VM is ok:

select count(*) from all_objects where object_type like 'JAVA%';

should return more than 4000 (could be 9000+, depending on options loaded.) This query checks if JDK classes are all loaded and registered and is used internally in one of initjvm.sql subscripts for sanity check.

-- 
Vladimir Zakharychev (bob@dpsp-yes.com)                http://www.dpsp-yes.com
Dynamic PSP(tm) - the first true RAD toolkit for Oracle-based internet applications.
All opinions are mine and do not necessarily go in line with those of my employer.
Received on Tue Nov 26 2002 - 03:04:18 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US