Scalable Database Server, HiRDB Version 8 UAP Development Guide

[Contents][Index][Back][Next]

18.2 SQLJ Translator

SQLJ Translator analyzes an SQLJ source program and generates a Java source file and a profile.

SQL statements are replaced with Java instructions, including the invocation of the JDBC API, and are output as a Java source file.

SQL character strings, number of parameters, types and modes of individual parameters, and the description of the columns to be output to a profile. The profile is referenced from the SQLJ Runtime Library. The entity of a profile is an instance of the java.sql.runtime.Profile class.

Table 18-1 lists the files that are generated and referenced by the SQLJ Translator.

Table 18-1 Files that are generated and referenced by the SQLJ Translator

File classification File name format Explanation Type
SQLJ source file file-name.sqlj Indicates an SQLJ source file. Referenced
Java source file file-name.java Indicates a Java source file. Generated
Profile file-name_SJProfile profile-number.ser Stores the information of each SQL statement extracted from an SQLJ source file. A profile number is assigned to each context. The cardinal number is 0 for all. Generated

The prefixes of the classes and variables internally generated by SQLJ Translator are as follows:

_sJT_: Names of the variables internally generated

_SJ: Names of the classes and profiles internally generated