SQL>conn / as sysdba:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />
SQL> grant javauserpriv to scott;
권한이
부여되었습니다.
SQL> conn scott/tiger
연결되었습니다.
SQL> create or replace java source named "Hello"
as
2 public class Hello { /* Pure Java
Code
*/
3 static public String
Msg(String tail) {
4 return "Hello " +
tail;
5
}
6 }
7 /
Java가 생성되었습니다.
SQL> create or replace function hello (str varchar2) return varchar
as
2 language java name
'Hello.Msg(java.lang.String) return java.lang.St
ring';
3 /
함수가
생성되었습니다.
SQL> select hello('OnJProgramming, OracleJava Community') from
dual
2 ;
HELLO('OnJProgramming, OracleJava
Community')
--------------------------------------------------------------------------------
Hello OnJProgramming, OracleJava Community
댓글 없음:
댓글 쓰기