Hierarchy Chart for payedit.cbl

This hierarchy chart shows the breakdown of the routines in the payedit program. As you can see, it starts with the mainline which performs three routines: A-100-STARTUP, B-100-PROCESS, and C-100-WRAPUP. On the chart I put in the letters A, B, and C across the top to show the groupings and the numbers 100, 200, 300 down the side to show the levels. I would not do that if I were drawing the chart professionally.

The logic of these programs has both A-100-STARTUP and C-100-WRAPUP as one time occurances, in other words they are executed once.
B-100-PROCESS controls the processing of all of the records in the file. Therefore it is controlling MANY executions. The B-200-LOOP is where each record is processed so it fact it is the thing that is done MANY times. The B-200-LOOP controls when the B-300-HDR-ROUT will be executed and when the B-310-EDIT-RECORD routine will be executed. The header is done whenever there is a page break and the edit routine is done one for each record in the file.
The B-100-PROCESS routine also determines when the B-210-TOTAL-ROUT is executed. This is executed once when the rest of the processing is complete.