SQL/MX 2.x Reference Manual (G06.24+, H06.03+)
Embedded-Only SQL/MX Statements
HP NonStop SQL/MX Reference Manual—523725-004
3-29
Considerations for DECLARE MPLOC
Considerations for DECLARE MPLOC
Preprocessor and INVOKE Directive
The way you specify DECLARE MPLOC affects whether the preprocessor preserves
or overrides the INVOKE directive:
Scope of DECLARE MPLOC
You can specify more than one DECLARE MPLOC directive in an embedded SQL
program. Each directive replaces the preceding directive and stays in effect until it is
replaced by another directive or until the end of the program’s compilation unit is
reached.
If no DECLARE MPLOC directive is in effect when the SQL/MX compiler encounters
an unqualified Guardian physical name, the compiler uses the volume and subvolume
as determined by NonStop SQL/MX. For more information, see Object Naming on
page 10-47 and the SQL/MX Programming Manual for C and COBOL or the SQL/MX
Programming Manual for Java.
C Examples of DECLARE MPLOC
•
Set the default volume and subvolume:
EXEC SQL DECLARE MPLOC '$MYVOL.MYSUBVOL';
DECLARE MPLOC is specified as... INVOKE Directive Preprocessor Action
\node.$vol.subvol.filename table is not fully qualified
and does not contain
\node.
Overrides the
INVOKE directive with
DECLARE MPLOC
names.
\node.$vol.subvol.filename table contains \node. Preserves the
INVOKE directive and
does not use
DECLARE MPLOC
names.
$vol.subvol.filename table is not fully qualified
and does not contain
\node.
Overrides the
INVOKE directive with
DECLARE MPLOC
names.
$vol.subvol.filename table contains \node. Preserves the
INVOKE directive and
does not use
DECLARE MPLOC
names.
C/COBOL