HP NonStop SQL/MP Programming Manual page 136

For c
Table of Contents

Advertisement

Explicit Program Compilation
COMPILE { PROGRAM [ STORE SIMILARITY INFO ] }
{ INVALID PLANS
{ INOPERABLE PLANS
determines which SQL statements are compiled during an explicit SQL
compilation. You can direct the SQL compiler to use the similarity check to
determine if a statement's execution plan from a previous compilation is operable.
The SQL compiler then recompiles only the statements that fail the similarity
check. Other SQL statements retain their existing plans.
To use a COMPILE option, you must have an SQL/MP software version of 310 (or
later). A version 310 SQL compiler sets the PFV to 310. To support the COMPILE
PROGRAM STORE SIMILARITY INFO, COMPILE INVALID PLANS, or COMPILE
INOPERABLE PLANS option, an SQL catalog must have a catalog version of 310
(or later).
If you specify the COMPILE PROGRAM STORE SIMILARITY INFO, COMPILE
INVALID PLANS, or COMPILE INOPERABLE PLANS option (which stores
similarity information in the program file), the SQL compiler sets the PCV to 310. If
you omit the COMPILE option or specify the COMPILE PROGRAM option (the
default), the SQL compiler sets the PCV to 1 (unless the program includes other
version 310 features).
COMPILE PROGRAM
directs the SQL compiler to explicitly compile all SQL statements in the
program. If you include the STORE SIMILARITY INFO clause, the SQL
compiler also stores similarity information for each SQL statement in the
program file. COMPILE PROGRAM is the default.
COMPILE INVALID PLANS
directs the SQL compiler to explicitly compile these SQL statements:
Statements that reference changed DEFINEs.
Statements with plans that fail the redefinition timestamp check.
Statements with altered execution plans, which are invalid but operable
plans that the SQL compiler has updated without recompiling.
Uncompiled SQL statements with empty sections. The SQL compiler
generates an empty section if an SQL statement references a nonexistent
DEFINE or SQL object. (The SQL compiler also generates empty sections
for CONTROL directives and DDL statements.)
Other SQL statements retain their existing execution plans.
The COMPILE INVALID PLANS option stores similarity information in the
program file and updates the program's USAGES tables.
HP NonStop SQL/MP Programming Manual for C—429847-008
Running the SQL Compiler in the Guardian
6-20
Environment
}
}

Advertisement

Table of Contents
loading

Table of Contents