Prevention of position errors when copying files
When the copy file function cannot locate the first record to copy in the from-file member, a position error occurs. This can happen when using the CPYF, CPYSRCF, or CPYTOTAP commands. If any of the following conditions are true, you might receive a position error for the from-file member:
- You specified the FROMKEY parameter, and all records in the member are less than the FROMKEY value or the member is empty.
- You specified the FROMRCD parameter beyond the end of the member or the member is empty.
- The value of the from-file member position (the POSITION parameter of the OVRDBF command) is beyond the end of the member, is not valid for the access path of the from-file, or the member is empty.
If a member position error occurs, the member cannot be added to the to-file, and no information about the member is added to the print lists.
If a member position error occurs during a copy operation that involves multiple members, the copy operation will continue with the next member.
If a member position error occurs for all members, a print list is not produced, and the to-file cannot be created.
Parent topic:
Preventing errors when copying files