Copies a retained JAR and the classes it contains from an Adaptive Server into a client file. Located in $SYBASE/OCS-12_5/bin.
In Windows NT, the utility is extrjava.exe, and is located in %SYBASE%\OCS-12_5\bin.
extractjava (extrjava in Windows NT) -j jar_name -f file_name [-S server_name] [-U user_name] [-P password] [-D database_name] [-I interfaces_file] [-a display_charset] [-J client_charset] [-z language] [-t timeout] [-v]
Or
extractjava -v
the name assigned to the retained JAR in the database that is the source of the transfer.
the name of the client file that is the target of the transfer.
the name of the server.
an Adaptive Server login name. If you omit the -U flag and parameter, or if you specify the -U flag with no parameter, Adaptive Server uses the current user’s operating system login name.
an Adaptive Server password. If you omit the -P flag and parameter, extractjava prompts for a password. If you specify the -P flag with no password, the null password is used.
the name of the database in which to install the JAR. If you omit the -D flag, or if you specify the -D flag with no parameter, the user’s default database is used.
the name and location of the interfaces file to search when connecting to Adaptive Server. If you omit the -I flag and parameter, or if you specify the -I flag with no parameter, the interfaces file in the directory designated by your SYBASE environment variable is used.
allows you to use extractjava from a machine where the character set differs that of the server. Use -a in conjunction with -J to specify the character set translation file (.xlt file) required for the conversion. Use -a without -J only if the client character set is the same as the default character set.
specifies the character set to use on the client. extractjava uses a filter to convert input between client_charset and the Adaptive Server character set.
-J client_charset requests that Adaptive Server convert to and from client_charset, the character set used on the client.
-J with no argument disables character set conversion. Use this if the client and server use the same character set.
Omitting -J sets the character set to a default for the platform, which may not necessarily be the character set that the client is using. See the System Administration Guide for more information about character sets and associated flags.
the name of an alternate language for displaying extractjava prompts and messages. Without the -z flag, extractjava uses the server’s default language. You can add languages to an Adaptive Server during installation or afterward, using the langinstall utility or the sp_addlanguage stored procedure.
specifies the number of seconds before a SQL command times out. If you do not specify a timeout, the command runs indefinitely. This affects commands issued from within extractjava, not the connection time. The default timeout for logging into extractjava is 60 seconds.
prints the version number and copyright message for extractjava and then exits.
Downloads the classes associated with the employees JAR to the client file newaddr.jar.
In UNIX:
extractjava -j employees -f '/home/usera/jars/addr.jar' -new
In Windows NT:
extrjava -j employees -f '\home\usera\jars\addr.jar' -new
You must set the SYBASE environment variable to the location of the current version of Adaptive Server before you can use extractjava.
If the target client file already exists, extractjava overwrites its contents.
The parameter flags -f, -j, -S, -U, -P, -D, and -I can be written with or without a space between the flag letter and the following parameter.
When you execute extractjava, an exclusive lock is placed on sysxtypes.
If -jar is specified, an exclusive table lock is placed on sysjars.
See Java in Adaptive Server Enterprise for more information about how this utility is used when Java is enabled in the database.
You need to be a System Administrator or Database Owner to use extractjava.
sysjars, sysxtypes
Commands – remove java
System procedures – sp_helpjava
Utilities – installjava