Reader Feedback and Insights: Copying Records in RPG
September 6, 2002 Timothy Prickett Morgan
Hey, Ted:
I’m writing about the August 23 Midrange Guru Tech Tips regarding moving records between files with different field names. One option that I didn’t see, and the one I now prefer, with RPG IV is using the prefix keyword to rename the fields from one of the files.
Here’s an example:
Fpaywork if e k disk Fpayhist o e disk prefix(pw : 2) C read paywork C dow not %eof(paywork) C write histrec C read paywork C enddo C eval *inlr = *on
|
— Scott
Good idea, Scott. A few other readers suggested the same thing. That