rem ----------------------------------------------------------------------- rem Filename: java.sql rem Purpose: Demonstrate Java stored procedures (available from Oracle 8i) rem Date: 28-Aug-1998 rem Author: Frank Naude (frank@onwe.co.za) rem ----------------------------------------------------------------------- conn / as sysdba -- @?/javavm/install/initjvm.sql grant javauserpriv to scott; conn scott/tiger create or replace java source named "Hello" as public class Hello { static public String Msg(String tail) { return "Hello " + tail; } } / -- SHOW ERRORS not needed create or replace function hello (str varchar2) return varchar as language java name 'Hello.Msg(java.lang.String) return java.lang.String'; / show errors select hello('Frank') from dual /