Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 12.0.1 » SQL Anywhere Server - Programming » Java in the database » Installing Java classes into a database


Installing a JAR

It is useful and common practice to collect sets of related classes together in packages, and to store one or more packages in a JAR file.

You install a JAR file the same way as you install a class file. A JAR file can have the extension JAR or ZIP. Each JAR file must have a name in the database. Usually, you use the same name as the JAR file, without the extension. For example, if you install a JAR file named, you would generally give it a JAR name of myjar.

 Install a JAR (Sybase Central)
  1. Connect to the database as a user with DBA authority.

  2. Open the External Environments folder.

  3. Under this folder, open the Java folder.

  4. Right-click the right pane and click New » JAR File.

  5. Follow the instructions in the wizard.

 Install a JAR (SQL)
  1. Connect to a database as a user with DBA authority.

  2. Execute the following statement:

    JAR 'jarname'
    FROM FILE 'path\\JarName.jar';
 See also