MAP

Use MAP to produce a listing of the items defined in the DATA DIVISION.

MAP option syntax

Read syntax diagramSkip visual syntax diagramNOMAPMAP

Default is: NOMAP

Abbreviations are: None

The output includes the following items:

  • DATA DIVISION map
  • Nested program structure map, and program attributes
  • Size of the program's WORKING-STORAGE and LOCAL-STORAGE

If you want to limit the MAP output, use *CONTROL MAP or NOMAP statements in the DATA DIVISION. Source statements that follow *CONTROL NOMAP are not included in the listing until a *CONTROL MAP statement switches the output back to normal MAP format. For example:


*CONTROL NOMAP            *CBL NOMAP
    01  A                     01  A
    02  B                     02  B
*CONTROL MAP              *CBL MAP

When the MAP option is in effect, you also get an embedded MAP report in the source code listing. The condensed MAP information is shown to the right of data-name definitions in the WORKING-STORAGE SECTION, FILE SECTION, LOCAL-STORAGE SECTION, and LINKAGE SECTION of the DATA DIVISION. When both XREF data and an embedded MAP summary are on the same line, the embedded MAP summary is listed first.

Example: MAP output

Related concepts  
Debugging

Related tasks  
Getting listings

Related references  
*CONTROL (*CBL) statement (COBOL for Linux® on x86 Language Reference)