SQL/MX Programming Manual for C and COBOL (H06.04+)
C/C++ Program Compilation
HP NonStop SQL/MX Programming Manual for C and COBOL—540434-001
15-31
MXCMP Environment Variable
You can run mxCompileUserModule more than once.
mxCompileUserModule extracts the application-file’s selected module
definitions. For each selected module definition m, mxCompileUserModule passes m
to mxcmp for SQL compilation. Each compilation of a selected module definition either
succeeds or fails just like any mxcmp invocation. An mxcmp compilation failure does not
affect preceding or following mxcmp invocations. In particular, an mxcmp compilation
failure does not prevent mxCompileUserModule from proceeding with the mxcmp
compilation of the next selected module definition.
Examples—mxCompileUserModule
•
This command compiles the embedded module definition:
mxCompileUserModule sqlprog.exe
•
This command places the module file in the same OSS directory as the application
executable:
mxCompileUserModule -g moduleLocal sqlprog.o
•
These settings affect statement recompilation at execution time:
mxCompileUserModule -d AUTOMATIC_RECOMPILATION=ON \
-d SIMILARITY_CHECK=ON sqlprog.o
MXCMP Environment Variable
To specify an alternate location of the SQL/MX compiler (MXCMP) instead of the
default location of /G/system/system/mxcmp, use the MXCMP environment variable.
This environment variable is used by c89 and the mxCompileUserModule utility and
enables you to direct c89 or mxCompileUserModule to use another version of the
MXCMP executable.
To set the MXCMP environment variable, enter this command at an OSS prompt before
invoking the c89 or mxCompileUserModule utility:
export MXCMP="/G/usr/mydir/mxcmp"
For more information, see the Open System Services Shell and Utilities Reference
Manual.
MXCMPUM Environment Variable
To specify an alternate location of the compiler utility (mxCompileUserModule)
instead of the default location of
/usr/tandem/sqlmx/bin/mxCompileUserModule, use the MXCMPUM
environment variable. This environment variable is used by the c89 utility and enables
you to direct c89 to use another version of the mxCompileUserModule utility.










