SQL/MX 2.x Installation and Management Guide (G06.24+, H06.03+)
Managing Database Applications
HP NonStop SQL/MX Installation and Management Guide—523723-004
11- 6
Moving a Program Without Compiled Modules
subvolume on the command line during SQL compilation of the module
definition:
mxCompileUserModule -d MP_VOLUME=\$vol MP_SUBVOLUME=subvol
myprog.exe
mxcmp -d MP_VOLUME=\$vol MP_SUBVOLUME=subvol sqlprog.m
•
For hard-coded logical names of SQL/MX objects, make sure that catalog,
schema, and object names on the development system are the same as those on
the production system.
•
If catalog and schema names on the development system differ from those on the
production system, omit the catalog and schema from SQL/MX object names in the
program. The object names are qualified with the default catalog and schema of
the system on which the statements are compiled.
°
For SQLJ programs, you can override the default catalog and schema of
unqualified objects by setting the catalog and schema on the command line
during customization:
java sqlj.tools.Sqlj -catalog=cat -schema=sch MyProg.jar
°
For embedded SQL programs in C, C++, or COBOL, you can override the
default catalog and schema of unqualified objects by setting the catalog and
schema on the command line during SQL compilation of the module definition:
mxCompileUserModule -d CATALOG=cat -d SCHEMA=sch
myprog.exe
mxcmp -d CATALOG=cat -d SCHEMA=sch sqlprog.m
For more information, see name resolution in the SQL/MX Programming Manual for C
and COBOL and the SQL/MX Programming Manual for Java.
Steps for Moving to a Production System
These instructions explain how to move a program with its uncompiled module
definitions (either embedded module definitions or module definition files) from a
development system to a production system. After moving the program to the
production system, you must SQL compile the module definitions on the production
system.
Assumptions
For the purpose of the examples, suppose that:
•
Two NonStop server systems, \DEV and \PROD, are connected by an Expand
network. For more information, see the Introduction to Networking for HP NonStop
S-Series Servers.
Note. This technique works only for database objects that belong to the same catalog and
schema. If the program refers to database objects in different catalogs and schemas, you
must hard code those catalogs and schemas in the program.