SQL/MP Programming Manual for COBOL85

Explicit Program Compilation
HP NonStop SQL/MP Programming Manual for COBOL85429326-004
6-23
The nld Utility
SQL compile only the final bound object; you are not required to separately SQL
compile each object of a multiple-module program.
Give a COBOL program a unique program name if you plan to bind it with other
programs.
To run the Binder program, enter BIND at the TACL prompt. The Binder program
displays its banner and prompt, an at sign (@).
In this example, the Binder commands combine the COBOBJ1 and COBOBJ2 files into
an executable object file named PROGFILE. The SELECT LIST * OFF command
improves system performance by turning all listings off.
@ADD * FROM cobobj1
@ADD * FROM cobobj2
@SELECT LIST * OFF
@BUILD progfile
For more information about the Binder program, see the Binder Manual.
The nld Utility
This subsection applies only to native objects created with the NMCOBOL compiler.
The COBOL85 compiler does not use the nld utility, it uses Binder. See The
Binder Program on page 6-22.
The NMCOBOL compiler validates and resolves internal and external references with
the help of the COBOLFE process and the nld utility. The nld utility accepts
commands that direct it to read, operate on, and produce object files.
The nld utility links one or more object files to produce an executable or
nonexecutable native object file. An executable native object file cannot be input to the
nld utility at a later time; a nonexecutable native object file can.
For more information on the nld utility, see the nld and noft Manual.
The SQL Compiler
The SQL compiler (SQLCOMP) generates SQL object code in the program file.
SQLCOMP verifies SQL objects used in SQL statements and generates an optimized
execution plan for each SQL statement. Optionally, you can invoke the EXPLAIN utility
Note. In an OSS environment, the Binder is invoked by the cobol utility through the
-Wbind flag. For more information, see Running the COBOL85 Compiler in the OSS
Environment on page 6-13, or the Open System Services Shell and Utilities Reference
Manual.
Caution. The Binder STRIP command without the SYMBOLS or AXCEL option removes the
Binder table from an SQL program file. Without the Binder table, the SQL compiler cannot
compile the program file, and the SQL executor cannot execute it.