This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

RM/COBOL Identify COPYBOOK FROM LOAD

Hi -

I need a help to locate copybook version used in RM/COBOL obj modules.

Problem :  My platform maintained 2 version of  same copybook. 

Ex: Folder#1     Copybook:-  C1.CPY

Ex: Folder#2     Copybook:-  C1.CPY

I have list [cannot be trusted] which tell me to call shell#1 [using Folder#1] to compile or sell#2 to compile[Folder#2] for a program. Mostly, I need to find once start working in a program.

I have listing file that also cannot be trusted. 

I have huge number of programs to be compiled. Is it possible to find out any information from load  or some other way  like generating listing from COBOL load?

Tags:

  • 0

    If the program was compiled with Y=3 (extended debugging information), then you can find the filename and pathname of all of the copy files in the last few 256-byte blocks of the file. You might also see the text of the COPY file itself, or some listing information which is saved there for use by CodeWatch. These blocks are only added if Y=3 is specified at compile time. You'll also have to hex-dump the file because it's binary and most text editors won't open it or read the entire thing.

    Otherwise, the COPY file information is not saved in the object file. If I understand the problem correctly, the only other suggestion I can make is to compile the program both ways and compare the .COB files against the original .COB file, ignoring the date/time/version differences in the first 256-byte block. With version 12, the rest of the original file should match one of the two new files.