From MidrangeWiki
Jump to: navigation, search

STRDBG starts the standard debugger. An alternative debugger is called the System Debugger. It is a Java application. Also, RDp has n interactive debugging facility called the System Entry Point debugger.

Debug tips

  • Unreferenced fields show blanks.
    • In RPG H specification, set DEBUG(*YES) or DEBUG(*INPUT)
  • Seeing more than 1024 bytes of a character field, DS or array.
    • EVal Field :c number_of_bytes
  • Seeing the hex values of fields.
    • EVal Field :x number_of_hex_pairs
  • Positioning quickly to break points. This only finds break point line.
    • Next, Previous
  • Positioning to the next statement that can have a break point set
    • F6 from the top of the source positions to the first F-specs
    • F6 from the D-specs positions to the first I-spesc or C-specs if no I-specs.
    • Note: remember to remove the break point set, if its not what you wanted.

Debugging other jobs

Usually called service debugging. You need to start the other job in service mode with STRSRVJOB. Run then STRDBG over the program. Be prepared to watch the screen flash if you step through code. The job to be service must be active in the system in order to use STRSRVJOB.