Installing SQLJ

Install the Java Development Kit 1.1 or later (you can get it from www.sun.com). Note that JDK 1.0.2 will not do. Make sure that the current directory ''.'' is in your CLASSPATH. You should now be able to say java and javac.

Get an Oracle JDBC driver (unless you already have one installed). It contains the file classes111.zip (and classes12.zip if you are using JDK 1.2), which must be placed in your CLASSPATH. Depending on the type of driver you use, you might also need a dynamic library (*.so or *.dll) in your LD_LIBRARY_PATH or, respectively, PATH. Follow the JDBC installation instructions for this. You should now be able to compile and run JDBC programs.

  • See also JDBC Developer's Guide and Reference, Chapter 2, Section "Verifying a JDBC Client Installation".
If you obtained Oracle SQLJ from an Oracle8i or later database installation, then you have an [Oracle Home]. The SQLJ executable (named sqlj or sqlj.exe depending on your flavor of operating system) lives in [Oracle Home]/bin, which will be in your PATH. You must also put [Oracle Home]/sqlj/lib/translator.zip —which contains the SQLJ translator— in your CLASSPATH.

If you obtained Oracle SQLJ from the Oracle website, you must perform a bunch of untarring and (g-)unzipping, and you will eventually end up with a sqlj directory. The executable lives in sqlj/bin and must be in your PATH, and the sqlj/lib/translator.zip file must be in your CLASSPATH.

Are you greeted with a help screen when you say sqlj? Yes? Then you are in business!

  • Make sure that you have a JDK and the Oracle JDBC drivers properly installed before starting the SQLJ installation. Also, if you have several versions of Java or Java Development Environments installed, we recommend that you "build" up your PATH and your CLASSPATH environment from scratch to make sure to properly pick up a known Java and JDBC configuration. On NT, consider creating a .bat file that you can use in a DOS window to provide the appropriate setup.
  • If you are using SQLJ version 8.1.5 on NT, you must set SQLJ_OPTIONS=-passes.
  • For more details, see SQLJ Developer's Guide and Reference, Chapter 2, Sections "Checking the Installation and Configuration" and "Testing the Setup". While we mention only the translator.zip file in this discussion, you should distribute the runtime.zip file (not translator.zip) with any SQLJ applications that you create.

E-mail this page
Printer View Printer View
Oracle Is The Information Company About Oracle | Oracle RSS Feeds | Careers | Contact Us | Site Maps | Legal Notices | Terms of Use | Privacy