Register a routine written in Java

To register a Java™ routine, write the body of the routine, compile it, create a .jar file, and register the .jar file with install_jar(). Then use the CREATE FUNCTION or CREATE PROCEDURE statement to register the function. For example:
CREATE PROCEDURE showusers()
   WITH (class='jvp')
   EXTERNAL NAME 'thisjar:admin.showusers()'
   LANGUAGE java;

A UDR written in Java runs on a JVP by default. Therefore, the CLASS routine modifier in the preceding example is optional. However, it is recommended that, to improve readability of your SQL statements, you include the CLASS routine modifier when you register a UDR.

For more information, see the CREATE FUNCTION and CREATE PROCEDURE statements in the HCL OneDB™ Guide to SQL: Syntax. For information about how to create a Java routine, refer to the HCL® J/Foundation Developer's Guide.