Compaq COBOL AAQ2G1FTK User Manual

Page 59

Advertising
background image

Developing Compaq COBOL Programs

1.3 Developing Programs on OpenVMS Alpha

You can use the COPY FROM DICTIONARY statement in your program to access
a data dictionary and copy Oracle CDD/Repository record descriptions into your
program as COBOL record descriptions. Before you can copy record descriptions
from Oracle CDD/Repository, you must create the record descriptions using the
Common Data Dictionary Language (CDDL) or Common Dictionary Operator
(CDO).

For more information about using Oracle CDD/Repository and creating and
maintaining text libraries, refer to the Compaq COBOL Reference Manual and
Using Oracle CDD/Repository on OpenVMS Systems.

1.3.2 Compiling a Compaq COBOL Program on OpenVMS Alpha

To compile your program, use the COBOL command. The Compaq COBOL
compiler performs these primary functions:

Detects errors in your program

Displays each compiler message on your terminal screen

Generates machine language instructions from valid source statements

Groups these language instructions into an object module for the linker

Creates an analysis file if you request it with the /ANALYSIS_DATA qualifier.
SCA uses this file to display information about program symbols and source
files.

The compiler outputs an object module that provides the following information:

The name of the entry point. It takes this name from the program name in
the first PROGRAM-ID paragraph in the program.

A list of variables that are declared in the module. The linker uses this
information when it binds two or more modules together and must resolve
references to the same names in the modules.

Traceback information. This information is used by the system default
condition handler when an error occurs that is not handled by the program.
The traceback information permits the default handler to display a list of the
active blocks in the order of activation; this is an aid in program debugging.

A symbol table and a source line correlation table, only if you request them
with the /DEBUG qualifier. A symbol table is a list of the names of all
external and internal variables within a module, with definitions of their
locations. The source line correlation table associates lines in your source file
with lines in your program. These tables are of primary help when you use
the OpenVMS Debugger.

To invoke the Compaq COBOL compiler, use the COBOL command (explained
in Section 1.3.2.1). You can specify qualifiers with the COBOL command. The
following sections discuss the COBOL command and its qualifiers.

1.3.2.1 Format of the COBOL Command on OpenVMS Alpha

The COBOL command has the following format:

COBOL [/qualifier] ... {file-spec [/qualifier] ...} ...

Developing Compaq COBOL Programs 1–29

Advertising