Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

FILE STATUS? 3

Status
Not open for further replies.

rpangel

Programmer
Jun 12, 2001
29
US
In COBOL, what does the error message FILE STATUS = 39 mean? And, what is a common way to go about fixing it?
 
HI,
File status 39 means:
The file organization specified for the file name does not
match the actual file organization of the physical file.
this is for RM/COBOL.
Other error Message under 39, pls specify Cobol/runtime.
There are 39,01 39,02 39,03 .......

 
Hi,

the COBOL 85 standard says for file-status 39:

error on OPEN because the properties of the file are not compatible with those defined in the program.

If you want to fix it, you should know what is wrong with the output file.

To avoid the problem, you can write a small program that opens the same kind of file for output and writes something.
After that, you compare the output file with the original one to find out what the differences are....

Regards,

Crox
 
Fujitsu COBOL returns a 39 when a file is corrupt, in addition to returning that status when the FD doesn't match the actual file layout.
 
The most ommon causes of this error are wrong file organization, wrong record length, wrong key position or key length, and fixed vs variable length records.

Hope this helps Betty Scherber
Brainbench MVP for COBOL II
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top