Ask the Expert

Processing multi files in RPGIII

How can you process multi files in RPGIII that can be genetic names, example: EXAMPLE ABC0412, ABC0413, ABC0414 ETC.


I would assume that your question is how to create a single program to process files with different data, but the same data format. The CL command OVRDBF will allow you to override the file name in the RPG program to open a different file name.

 Example:
FILEA - Original File.
FILEB - New file that has just arrived.
PGMA - Program was written to use FILEA.
CL Commands:
CALL PGMA - Calls program "A" and processes FILEA
OVRDBF FILE(FILEA) TOFILE(*LIBL/FILEB)
CALL PGMA - Calls program "A" and processes FILEB 

This was first published in April 2001

There are Comments. Add yours.

 
TIP: Want to include a code block in your comment? Use <pre> or <code> tags around the desired text. Ex: <code>insert code</code>

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
Sort by: OldestNewest

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to: