Posted: Mon Sep 20, 2004 6:01 am Post subject: I am getting U4038 abend with file status code 39
Hi,
please help me how to solve this abend.
my requirement is one vsam esds file reading and writing into a flat file all the records. logical file in cobol and physical file in jcl lengths are same also i am getting this problem and i am getting in sysout genk value why it is coming please help me.
By
Pgorthi
Joined: 26 Nov 2002 Posts: 12378 Topics: 75 Location: San Jose
Posted: Mon Sep 20, 2004 6:34 am Post subject:
pgorthi,
File status code of 39 means A conflict has been detected between the fixed file attributes and the attributes specified for the file in the program. This is usually caused by a conflict with record-length, key-length, key-position or file organization.
Other possible causes are:
1. Alternate indexes are incorrectly defined.
2. The Recording Mode is Variable or Fixed or not defined the same as when the file was created.
Post your file declaration and the open statement. Also let us know the type of vsam cluster(ESDS, KSDS, RRDS, LDS)
Joined: 26 Nov 2002 Posts: 12378 Topics: 75 Location: San Jose
Posted: Mon Sep 20, 2004 9:26 am Post subject:
Pgorthi,
Did your code even compile? You defined A-NAME as PIC A(20). The same is for B-name and no-more-records variables. There is no such definition as A(20). It should be X(20). Your actual problem is with assign clause.
When you define an ESDS file in CObol you need to define with AS in the assign clause.
So change your asssign clause for your input esds from
Code:
SELECT A-ESDS-FILE ASSIGN TO DA-AESDSFI
to
Code:
SELECT A-ESDS-FILE ASSIGN TO AS-AESDSFI
and re-run the program
Also chec this link for a better understanding of processing vsam files.
thanks a lot kolusu i wrote in select clause instead of DA-AESDSFI, i over write AS-AESDSFI then it working fine if possible please give me suggestions for
KSDS and RRDS what i want to write in select clause logocal name naming standerd.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum