I’ve got an Oracle 10g database, and I have a third-party jar file(MQ jars). I want to be able to run a trigger in my database that ultimately runs code in store procedure to operate MQ series and sending messages.
. I can’t figure out how to specify a classpath for my jar file that will be recognized when I am executing trigger. How can I do this?
I’ve got an Oracle 10g database, and I have a third-party jar file(MQ jars).
Share
You can use
loadjava(ordbms_java.loadjava) to load classes or JARs into the database; but for a third party JAR that seems unwieldy. If it’s your database then you may be able to set theCLASSPATHto include the external files before starting the database. I don’t think your user sessionCLASSPATHor any other environment variable (for whoever is taking the action that causes the trigger to fire) will ever have any effect, not least for security reasons – you don’t want a user to be able to subvert the expected action by substituting their own Java code.