SQL/MX Programming Manual for C and COBOL (G06.24+, H06.03+)

Program and Module Management
HP NonStop SQL/MX Programming Manual for C and COBOL—523627-004
17-22
Grouping
reports.o \
utils.o \
-l zcplsrl \
-l zcrtlsrl \
-l zcresrl \
-l zcplosrl \
-l ztlhgsrl \
-l ztlhosrl \
-Bdynamic \
-l zclisrl \
-o invrep
/G/system/system/mxcmp reports.m
/G/system/system/mxcmp utils.m
After the application is built, these two module files exist:
/usr/tandem/sqlmx/USERMODULES/CAT.SCH.INVENTORY^REPORTS^^
/usr/tandem/sqlmx/USERMODULES/CAT.SCH.INVENTORY^UTILS^^
Now, all the application’s module files can be referred to by using one OSS file name
wild-card pattern:
ls /usr/tandem/sqlmx/USERMODULES/*.*.INVENTORY^*
rm /usr/tandem/sqlmx/USERMODULES/*.*.INVENTORY^*
Grouping Example: COBOL INVENTORY modules
In this COBOL example, an application is built from two modules, reports.ecbl and
utils.ecbl. mxsqlco names the COBOL and module definition file output according
to default rules. At this point, INVENTORY is used as the group name for all the
modules in an inventory application, enabling the module files to be referred to by
group name.
mxsqlco reports.ecbl -g moduleGroup=INVENTORY
mxsqlco utils.ecbl -g moduleGroup=INVENTORY
nmcobol is used to compile the pure COBOL files (reports.cbl and utils.cbl),
and nld links the compiled object files. The last step is to build the application using
mxcmp to compile the module definition files, reports.m and utils.m.
After the application is built, these two module files exist:
/usr/tandem/sqlmx/USERMODULES/CAT.SCH.INVENTORY^REPORTS^^
/usr/tandem/sqlmx/USERMODULES/CAT.SCH.INVENTORY^UTILS^^
Now, all the application’s module files can be referred to by using one OSS file name
wild-card pattern:
ls /usr/tandem/sqlmx/USERMODULES/*.*.INVENTORY^*
rm /usr/tandem/sqlmx/USERMODULES/*.*.INVENTORY^*
COBOL