BB622 RPG36
The BB622.rpg36.txt
RPG program is a simple program called by the main OCL program (likely BB600.ocl36.txt
) within the invoice posting workflow on an IBM System/36 environment. Its primary function is to copy records from the input file CFIFILE
to the output file CF0E020
, effectively adding records to a file used for further processing in the Customer Freight Invoice (CFI) system. The program is straightforward, with minimal logic, and does not include any revisions or complex processing. Below is a detailed explanation of the process steps, business rules, tables used, and external programs called.
Process Steps of the BB622 RPG Program¶
The BB622
program reads records from CFIFILE
and writes them to CF0E020
using the RPG cycle, with no transformations or validations.
- File Initialization:
- The program opens two files:
- Input File:
CFIFILE
: Primary input file (IP
), 80 bytes per record, disk-based. Contains customer freight invoice records.- Output File:
CF0E020
: Output file (O
), 80 bytes per record, add capability (A
), disk-based. Receives copied records.
-
Defines a record format for
CFIFILE
:RECORD
: Single field (positions 1–80) containing the entire record.
-
Record Processing:
- Reads each record from
CFIFILE
sequentially using the RPG cycle (NS 01
). -
For each record, executes an exception output operation (
EXCPTRECADD
) to write toCF0E020
. -
Output Processing:
- Writes the entire
RECORD
field (80 bytes) toCF0E020
using theEADD RECADD
specification. -
No modifications or validations are performed on the record data.
-
Cycle Completion:
- Processes all records in
CFIFILE
until the end of the file. - Closes all files and terminates.
Business Rules¶
- Direct Record Copy:
- Copies all records from
CFIFILE
toCF0E020
without modification. -
Assumes all records in
CFIFILE
are valid and suitable for output. -
No Validation or Filtering:
- Does not check record content, transaction types, or dates.
-
All records are written to
CF0E020
as-is. -
Integration with CFI System:
-
Adds records to
CF0E020
, which is likely used in the Customer Freight Invoice system for further processing or reporting. -
No Error Handling:
- Assumes
CFIFILE
exists and contains valid data, andCF0E020
can be written to without issues. -
No explicit error handling for file access or write failures.
-
Simple Workflow:
- Designed as a straightforward data transfer program within the invoice posting workflow.
Tables (Files) Used¶
- CFIFILE:
- Description: Customer freight invoice input file.
- Attributes: 80 bytes per record, primary input file (
IP
), disk-based. - Fields Used:
RECORD
(1–80): Entire record content.
- Purpose: Contains freight invoice records to be copied.
-
Usage: Read sequentially to process records.
-
CF0E020:
- Description: Customer freight invoice output file.
- Attributes: 80 bytes per record, output file (
O
), add capability (A
), disk-based. - Fields Used:
RECORD
(1–80): Entire record content.
- Purpose: Receives copied freight invoice records.
- Usage: Written with
EADD RECADD
.
External Programs Called¶
The BB622
RPG program does not call any external programs. It is a self-contained program that performs a simple copy operation from CFIFILE
to CF0E020
.
Summary¶
The BB622
RPG program, called by the main OCL (e.g., BB600.ocl36.txt
), performs a basic task in the invoice posting workflow by:
- Reading records from CFIFILE
(80 bytes) sequentially.
- Writing each record to CF0E020
without modification using an exception output operation.
- Terminating after processing all records.
Tables Used: CFIFILE
(input freight invoice records), CF0E020
(output freight invoice records).
External Programs Called: None.
This program supports the Customer Freight Invoice system by transferring records to a file for further processing, with minimal logic and no data transformation.