COBOL Manual for TNS/E Programs (H06.08+, J06.03+)
CONSULT and NOCONSULT
NOTE: The compiler ignores and issues a warning for the NOCONSULT directive.
CONSULT
adds the files that object-name-list specifies to the tertiary search list. (See Tertiary Search
List.)
object-name-list
can be continued onto subsequent lines, but the left parenthesis must appear on the same
directive line as the keyword CONSULT. Each continuation line for a CONSULT directive must
have a question-mark (?) in the indicator area. If a CONSULT directive spans multiple lines,
they must be consecutive (no blank lines, comment lines, or program text lines can intervene).
object-name
is the name of a TNS/E object file. It can be either a file-system file name or (in the Guardian
environment) a DEFINE name. If the file-system file name is not fully qualified with system,
volume, and subvolume names, the compiler uses the current default system, volume, and
subvolume names to complete the qualification. If object-name is in the OSS environment,
it is an OSS pathname.
object-name must specify either:
• A linkfile
• An archive file
• A DLL
• An import library
When object-name is an archive file, the entire archive file is generally not linked into
the target object file. Only those member files are linked that contain procedures named
either in the statement CALL (page 293) or in the statement ENTER (page 319) in the COBOL
program being compiled. Whenever a procedure is needed from a member file, the entire
member file is linked.
When object-name is an import library, the compiler assumes that the member programs
were compiled without the directive NONSTOP. If this is not true, the compiler issues
warning 369, which you can ignore.
If an HP COBOL program references object-name either in the statement CALL (page 293)
or in the statement ENTER (page 319), object-name must have been compiled with the
SYMBOLS directive (see SYMBOLS and NOSYMBOLS).
544 Program Compilation










