
Trival discussion follows:
Total Number of Records - 24 to *END is actually 25 records.
Costello used this confusion to short change Abbott in every movie they made. In the
film “In the Navy”, 1941. Costello also has three ways to prove that 7 times 13 equals 28.
.
To get 24 records subtract 23 and If the Total Number of Records -23 < 1 then use 1 as the COPY FROM RECORD NUMBER.
Phil

More serious, trival discussion.
There are a number of assumptions in either the CL or the RPG process
1 - no deleted records in the file
2 - no deleted records in the last 24 records
3 - the last 24 records in the file are really the records that you want
— see numerious discussions of Reuse Deleted Records in Physical File REUSEDLT(*YES)
Phil

If an RPG program calls the CL then the RPG should not have the Copy TO file open at the time of the call.
Phil

In RPG (or other HLL), an actual READ with a program counter will ignore deleted records. However, a CPYF with FROMRCD() is affected by deleted records.
If the file is first reorganized to condense deleted records, then the counts will match.
If the file is not reorganized and deleted records are possible, the RPG program can use an INFDS to capture the relative record number of the 24th record from the end. That relative record number can then be used for a CPYF FROMRCD() parameter.
Tom

rebekahalkhalifa@yahoo.com
Hello…
I wish you best Compliment of the season,with hope that you are physically and healthly alright,l do believe that this mail will reach in good condition. My name is Rebekah i saw your profile in www.itknowledgeexchange.techtarget.com and admire it, i think we can make it together, please i would like you to contact me through my email address:( rebekahalkhalifa@yahoo.com ) i will tell you more about myself, also send you my photo,as soon as you contact me back, hopping for your lovely reply soonest,
Rebekah….

















