SQL/MP Installation and Management Guide
Managing Database Applications
HP NonStop SQL/MP Installation and Management Guide—523353-004
10-40
Moving Programs Without Recompilation
Moving Programs Without Recompilation
These SQL compiler options can be useful in the management of SQL programs:
•
The REGISTERONLY option directs the SQL compiler to register a previously SQL
compiled program in a specific catalog without recompiling any SQL statements in
the program. You can use this option to install a program in a catalog after you
have SQL compiled and moved the program. Although the REGISTERONLY
option requires you to run the compiler, this option is more efficient than explicitly
recompiling the entire program.
If the REGISTERONLY ON option is used, the SQL compiler summary listing
specifies that the SQL statements were not compiled and the plans are
unchanged.
•
The NOREGISTER option directs the SQL compiler to compile a program without
registering the program in a catalog. You can then move the program by using a
FUP or SQLCI DUP command or the BACKUP and RESTORE programs. After the
move, you can run the program without recompiling or registering it in a catalog.
A program compiled with the NOREGISTER ON option can never be registered in
a catalog. If you try to register a program compiled with the NOREGISTER ON
option by using the REGISTERONLY ON option, the operation fails with an SQL
error. If a program was compiled with the NOREGISTER ON option and you need
to register the program in a catalog, you must explicitly recompile it with the
REGISTERONLY and NOREGISTER options set to OFF (or without these options
altogether, which is the default).
If the NOREGISTER ON option is used, the SQL compiler summary listing
specifies that the program is not registered in a catalog.
The REGISTERONLY and NOREGISTER options operate independently of similarity
checking, but the use of similarity checking with these options makes a move operation
more efficient by minimizing recompilations.
If you install a program with the REGISTERONLY option and the program was not
previously compiled with the CHECK INOPERABLE PLANS option, the SQL executor
forces the automatic recompilation of static SQL statements in the program unless the
program accesses the same tables at run time that it accessed during explicit SQL
compilation. This restriction does not apply to dynamic SQL statements.
Note. The REGISTERONLY and NOREGISTER options are mutually exclusive options.