This course expands upon the fundamental COBOL programming skills taught in the previous course of this series, Developing a COBOL Program. The course first describes general report concepts and the differences between program-described and externally described report files. It then shows how COBOL facilities can be used to enhance the readability of program output by formatting numeric fields. The techniques covered here will apply whether the output is in the form of a printed report or a display on a terminal screen. Next the course describes how to improve the appearance of printed reports by adding headings and footings and controlling vertical spacing. Finally, the course discusses a somewhat more complex example requiring the use of multiple control breaks to produce a report containing totals and subtotals.
Approximate Study Time: 6 hours
After completing this course, you should be able to:
- Identify the various components of typical business reports
- Describe common report types and their associated business uses
- Code the SELECT and ASSIGN clauses to identify a printer file that uses either an externally described report format or a program-described report format
- Code the COBOL statements to perform output editing, including character insertion, zero suppression, check protection, and character replacement, given a description of the desired results
- Code COBOL data definition statements to implement a given report layout
- Code WRITE statements to vary the vertical spacing of a report or to start a new page
- Design and code a COBOL program to create a simple report, including headings, page numbers, and footings, given a problem statement, the input data description for a sequential file, and a report layout
- Design and code a COBOL program to create a report using the COBOL automatic page control facility, given a problem statement, the input data description for a sequential file, and a report layout
- Design and code a COBOL program to create a report requiring multiple levels of group totals (multiple control breaks), given a problem statement, the input data description for a sequential file containing records with multiple control fields, and a desired report layout
Introduction to Output Formatting
Field Editing Basics
Advanced Field Editing
A COBOL Report Program - Part 1
A COBOL Report Program - Part 2
Using the Automatic Page Control Facility
Handling Control Breaks
Handling Multiple-Level Control Breaks
The course is suitable for entry-level programming students with no prior COBOL experience. It can also be taken by COBOL/400 programmers who want to learn ILE COBOL.
Before you begin your study of the material, you should know basic programming concepts and be acquainted with structured programming design techniques. In particular, you will be expected to understand program logic that is documented using pseudocode or structured flowcharts. You may have gained this knowledge from attending classes or from relevant work experience.
This course also assumes that you have a working knowledge of IBM i programming concepts and facilities. You can satisfy this prerequisite by successfully completing the courses in the following Manta series:
Finally, the course assumes that you have completed the previous course of this series: