HP RPG/XL Programmer's Guide (30318-90001)

7-: 9
:BUILD DUMPRPG;REC=-80,16,F,ASCII;DISC=512,8
Requesting an Error Dump. You can get an Error Dump automatically by
entering an S in the Error Log Field (column 55) of the Header
Specification. The dump is produced whenever an RPG error occurs. If
you only want certain errors to trigger a dump, put an N in column 55 or
leave it blank. Then enter an error response for those errors (which
include a dump) into the Error Response Field (columns 56-71).
(Alternatively, if you leave the Error Log Field blank and an error
occurs, the operator can select response 5. Response 5 terminates the
program and produces a dump.)
This figure shows a Header Specification that requests an Error Dump
whenever an RPG error occurs.
Figure 7-10. Requesting an Error Dump
Comments
1 This Header Specification requests an Error Dump and directs it
to a disc file.
Columns 7-14 name the disc file, DUMPRPG, that contains the
Error Dump.
Column 55 is S to request an Error Dump if an error occurs. The
program terminates immediately. When you use S, you cannot use
the Response Field (columns 56-71) to enter error responses.
Parts of the Error Dump. Program information is shown in the Error Dump
in logical groupings with appropriate titles. The dump is easy to read.
Figure 7-11 (spread over several pages) shows an Error Dump of the
program in Figure 4-23 (see the compiler listing for this program in
Figure 6-11 through Figure 6-16).
The first part of the dump, LIBRARY POINTERS, shows the addresses of the
pointers to various tables and storage areas used by the program. Each
pointer contains the address of the first word of the table or storage
area.