Creating a file named DIBDWF3 with an AS/400 query, to be read in
RPG was causing QRG2122.
Looking at a similar program written some time ago by someone else,
the query file read by RPG had a different record format name.
Using Google I found two links:
wasn't something I could do in a CL program
The following article leads me to wonder if there isn't a command to
change a record format name.
The only way I could find to solve this, was to use RNMOBJ to rename
the file. Then the record and file name have different names, a
similar to the above article. Do you know if there is a simple way to
change a record format name?
The compilation error in the RPG program attempting to read the file
300 FDIBDWF3 IF E DISK
400 * Query file
* 2122 300 RECORD NAME DIBDWF3 PREVIOUSLY DEFINED AS FILE NAME.
RECORD FORMAT(S): LIBRARY MY_LIB FILE DIBDWF3.
EXTERNAL FORMAT DIBDWF3 DROPPED DUE TO ERROR OR IGNORE.