Oracle Visual Information Retrieval Java Classes User's Guide and Reference
Release 8.1.7

Part Number A85333-01





Go to previous page Go to next page

Running Java Classes Examples

A sample file (program written in Java) is provided in the installation of Oracle Visual Information Retrieval Java Classes. This file provides examples of how to build Java applications. It demonstrates loading data from various sources into database objects, downloading data from database objects to the file system, extracting and displaying metadata from the media content, and comparing images for similarity.

The name of the Java sample file is

To run the Java sample file included with Visual Information Retrieval Java Classes, you must perform the following operations:

  1. Install Oracle8i with Visual Information Retrieval.

    You must have the Oracle8i database server with Visual Information Retrieval installed on a server machine.

  2. Check the values of local variables.

    All users must make sure that,, the JDK classes, and the SQLJ files are included in the CLASSPATH variable on the local machine, and the local directory containing the javac and java commands is included in the PATH variable on the local machine.

    Solaris users must make sure the directory that contains the file named is included in the LD_LIBRARY_PATH variable.

    Windows NT users must make sure that the directory that contains the file named ocijdbc8.dll is included in the PATH variable.

  3. Compile the Java file on your local machine.

    Using version 1.1.6 of the JDK, compile the sample programs using the following command:

  4. Connect to your database and run the SQL script that corresponds to your Java file.

    For the sample program to run, your database must include tables that contain a column of the appropriate object type. The Visual Information Retrieval Java Classes installation includes a SQL file that contains commands to create a new user, create a table, and add some sample data to the table.

    The name of the SQL script is VirExample.sql.


    The SQL script connects to the database as the user
    system, with a password of manager. Edit the SQL files to change the password or remove the CONNECT statement before running the script.

    Also, edit the directory path to reflect your schema. 

  5. Run the compiled Java program using the following command:

    java VirExample

For more information on the sample file, see the readme file.

Go to previous page Go to next page
Copyright © 1996-2000, Oracle Corporation.

All Rights Reserved.