*** Welcome to piglix ***

RPG II


RPG II is a very early and popular version of the IBM RPG programming language.

It was developed in the late 1960s and designed to work on the smallest IBM systems of the time such as the IBM 1130, IBM System/3, System/32, System/34, System/36. It was however also available for the System/370, The Singer System 10, Univac 90/25, 90/30, 90/40 and the Wang VS Series. ICL produced versions for its ICL 2903 system and for VME/K; and Burroughs Corporation produced an RPG II compiler with database extensions for its B1700 series of computers.

It has a number of unusual features, including: an implied processing loop; and that it is a fixed-format programming language, so that programs are difficult to read without a special debugging template.

RPG II is a fixed-format programming language, which means that code must be placed in exact column locations in order to generate correct results. There are eight different specification types, and separate coding forms are used to write each, and a special debugging template used as an aid to read program printouts.

Every RPG II program executes within an implied loop, the program cycle, which applies the program successively to every record of a file - this is documented via a "Logic Flow" diagram on the debugging template. Each record (individual punched card) would be compared to each line in the program, which would act upon the record, or not, based upon whether that line had an "indicator" turned "on" or "off" — from a set of logical variables numbered 01–99 for user-defined purposes, or other smaller sets based upon record, field, or report processing functions. Special variables such as UDATE, UYEAR, PAGE, and so forth, are filled when the program begins or when page overflow occurs, even though there is no explicit instruction for these activities. Total calculations and output are done at "total time," after the detail cycle when L1/LR has been set on by fixed logic.


...
Wikipedia

...