If you just want to change records in place, the
UPDATEopcode is sufficient. But if you want to insert new records within the file, you'll need to write to another member. Your program would copy records from the original source member to the new member. When a
DELETEopcode is found, change it to a comment before writing the record out. Then, also write out the new
UPDATEopcode. After the new member is written out, you can then copy it back to the original member.