The SQLJ.REPLACE_JAR system procedure replaces a jar file in a database.
SQLJ.REPLACE_JAR(IN JAR_FILE_PATH_OR_URL VARCHAR(32672), IN QUALIFIED_JAR_NAME VARCHAR(32672))
d:/todays_build/tours.jar
MYSCHEMA.Sample1
-- a delimited identifier. MYSCHEMA."Sample2"
If authentication and SQL authorization are both enabled, only the database owner has execute privileges on this procedure by default. See "Configuring user authentication" and "Configuring user authorization" in the Derby Security Guide for more information.
The database owner can grant access to other users. Since this procedure can be used to install arbitrary code (possibly from across the network) that runs in the same Java Virtual Machine as the Derby database engine, the execute privilege should be granted only to trusted users.
-- SQL statement CALL sqlj.replace_jar('c:\myjarfiles\newtours.jar', 'APP.Sample1') -- SQL statement -- replace jar from remote location CALL SQLJ.REPLACE_JAR('http://www.example.com/tours.jar', 'APP.Sample2')