Oracle8i SQLJ Developer's Guide and Reference Release 3 (8.1.7) Part Number A83723-01 |
|
Oracle provides a special customizer, SQLCheckerCustomizer
, that will perform semantics-checking on a profile that was produced during previous execution of the translator. This semantics-checking is similar to what is normally performed during translation of the source code.
This is particularly useful when the database to be used at runtime differs from what was available to use for semantics-checking during translation. In these circumstances, you can use SQLCheckerCustomizer
after deployment, against the runtime database, typically in a scenario where the source code is no longer available.
You can specify the checker to use. If you accept the default OracleChecker
front end, SQLCheckerCustomizer
will perform online semantics-checking using an appropriate online checker.
Following are examples of how to specify the Oracle customizer harness verify
option to run SQLCheckerCustomizer
in its default mode. Because it defaults to an online checker, you typically must provide connection parameters through the customizer harness user
, password
, and url
options. (The first example is a single wrap-around command line.)
sqlj -P-verify -P-user=scott -P-password=tiger -P-url=jdbc:oracle:oci8:@ Foo_SJProfile0.ser Bar_SJProfile0.ser sqlj -P-verify -P-user=scott -P-password=tiger -P-url=jdbc:oracle:oci8:@ *.ser
The verify
option results in the customizer harness instantiating and invoking the following class:
sqlj.runtime.profile.util.SQLCheckerCustomizer
This class coordinates semantics-checking of the SQL operations in the profile. You can specify a semantics-checker or accept the default OracleChecker
semantics-checker front end.
The -P-verify
option is equivalent to the following:
-P-customizer=sqlj.runtime.profile.util.SQLCheckerCustomizer
This overrides the customizer specified in the SQLJ -default-customizer
option.
sqlj -P-verify <conn params> profile_list
sqlj -P-verify <conn params> Foo_SJProfile*.ser
profile.verify
(You must also specify profiles, and typically customizer harness connection options, in the SQLJ command line.)
profile.verify
(You must also specify profiles, and typically customizer harness connection options, in the SQLJ command line.)
n/a
Like any customizer, SQLCheckerCustomizer
has its own options, which can be set using the -P-C
prefix on the SQLJ command line (or profile.C
, instead of -P-C
, in a SQLJ properties file).
SQLCheckerCustomizer
supports the following options:
checker
--Specify the semantics-checker to use. The default is the OracleChecker
front end, as for checking during SQLJ translation.
warn
--Specify the categories of warnings and messages to display during semantics-checking of the profile. This is equivalent to the SQLJ -warn
flag for warning categories during translation-time semantics-checking, supports the same settings, and uses the same defaults. See "Translator Warnings (-warn)".
The checker
option allows you to specify the semantics-checker to use in checking the SQL operations in a profile.
This defaults to the Oracle semantics-checker front end, oracle.sqlj.checker.OracleChecker
, which for SQLCheckerCustomizer
chooses an appropriate online checker for your environment. For more information about OracleChecker
, see "Semantics-Checkers and the OracleChecker Front End (default checker)".)
Following is a full command-line example, showing how to use the SQLCheckerCustomizer
checker
option, in conjunction with the customizer harness verify
option and connection options.
sqlj -P-verify -P-user=scott -P-password=tiger -P-url=jdbc:oracle:oci8:@ -P-Cchecker=abc.def.MyChecker *.ser
(This is a single wrap-around command line.)
-P-Cchecker=checker_class
-P-Cchecker=a.b.c.MyChecker
profile.Cchecker=checker_class
profile.Cchecker=a.b.c.MyChecker
oracle.sqlj.checker.OracleChecker
The warn
option is equivalent to the SQLJ translator -warn
option, allowing you to choose the categories of warnings and messages to be displayed as semantics-checking is performed on a profile.
For a complete description of the functionality and possible settings of these options, see "Translator Warnings (-warn)".
This defaults to the all,noverbose,noportable
settings, resulting in all warning categories except verbose
and portable
being enabled. You will receive any warnings regarding data precision, conversion loss for nullable data, and strict matching for named iterators. These are the same defaults as for warnings during SQLJ translation.
Following is a full command-line example, showing how to use the SQLCheckerCustomizer
warn
option, in conjunction with the customizer harness verify
option and connection options. This would result in only portability warnings being displayed.
sqlj -P-verify -P-user=scott -P-password=tiger -P-url=jdbc:oracle:oci8:@ -P-Cwarn=none,portable *.ser
(This is a single wrap-around command line.)
-P-Cwarn=comma-separated_list_of_flags
-P-Cwarn=none,verbose
profile.Cwarn=comma-separated_list_of_flags
profile.Cwarn=none,verbose
all,noverbose,noportable
|
![]() Copyright © 1996-2000, Oracle Corporation. All Rights Reserved. |
|