Dan,

cobol is different from rpg, in that the file section and working storage
can have the same field names with different values independent of each
other.

file input buffers are filled on read, output buffers must be filled on
writes and re-writes (i think).

i imagine the program must be very old, because db2 has had the ability to
update the key field values of a record 'in-place' rather than having to
delete and re-write, for a long time now.

verify that the output buffers of your file are being populated, then look
into changing the program to 're-write' the record with new key values
instead of delete/write.

hth,

rick

-----original message------
We have a COBOL program that deletes a record, moves new values into the
key fields and then writes a new record.  The expectation was that the old
field values from the deleted recortd would be retained and the
new record would be the same data, but with new key values.

We are seeing some records where the field values from the deleted record
are not retained.  Not totally sure the COBOL program in question is the
cause, but I thought I remembered the famous IBM phrase 'results may be
unpredictable' regarding variables from deleted records.  The program
would require generous unit, system, and regression testing - along with
similar management signoffs - so I thought I would get some feedback
first.

Comments?


Dan Rasch


As an Amazon Associate we earn from qualifying purchases.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.