| Oracle8i SQLJ Developer's Guide and Reference Release 2 (8.1.6) A81360-01 |
|
To complement the loadjava utility, Oracle provides the dropjava utility to remove (drop) Java source, class, and resource schema objects. It is recommended that any schema object loaded into the server using loadjava be removed using dropjava only. This section presents only an overview of dropjava; it is discussed in detail in the Oracle8i Java Developer's Guide.
The dropjava utility transforms command-line file names and .jar file contents to schema object names, then removes the schema objects from the database. You can enter .sqlj, .java, .class, .ser, and .jar files on the command line in any order.
You should always remove Java schema objects in the same way that you first loaded them. If you load a .sqlj source file and translate it in the server, then run dropjava on the same source file. If you translate on a client and load classes and resources directly, then run dropjava on the same classes and resources.
For example, if you run loadjava on Foo.sqlj, then execute dropjava on the same file name, as follows:
dropjava -user scott/tiger Foo.sqlj
If you translate your program on the client and load it using a .jar file containing the generated components, then use the same .jar file name to remove the program:
dropjava -user scott/tiger Foo.jar
If you translate your program on the client and load the generated components using the loadjava command line, then remove them using the dropjava command line, as follows (presume there were no iterator classes):
dropjava -user scott/tiger Foo*.class dir1/dir2/Foo_SJProfile*.ser