IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

CICS cobol pgm : using a VSAM KSDS in edit mode :


IBM Mainframe Forums -> CICS
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
yussaf.khan

New User


Joined: 05 Jun 2008
Posts: 7
Location: india

PostPosted: Mon Sep 03, 2012 11:05 am
Reply with quote

I have a CICS cobol program that uses a VSAM KSDS with read + update. I execute this program/TRAN which fails with EIBRESP=16 , EIBRESP2 = 20. This means that an update attempt is being done for the file, defined as read only.

However, I have defined the file using RDO CEDA for update.
Code:

OBJECT CHARACTERISTICS                   
 CEDA  View File( FILEPER  )             
  File           : FILEPER               
  Group          : AFIAG01               
  DEScription    : PERSONNEL DB         
 VSAM PARAMETERS                         
  DSNAme         : AFIA.PER.KSDS.CLUSTER
. . .
. . .
  RECORDFormat   : F             
 OPERATIONS                     
  Add            : Yes           
  BRowse         : Yes           
  DELete         : Yes           
  READ           : Yes           
  UPDATE         : Yes           


I also did a CEMT INQ on this file, which shows that the file is for read only.
Code:

INQ FI(FILEPER)                                             
STATUS:  RESULTS - OVERTYPE TO MODIFY                       
 Fil(FILEPER ) Vsa Ope Ena Rea                     Sha     
        Dsn( AFIA.PER.KSDS.CLUSTER                        )

Could some one please help by explaining why the CEMT & CEDA results are different and... how do we fix this?

Thanks
Back to top
View user's profile Send private message
Pandora-Box

Global Moderator


Joined: 07 Sep 2006
Posts: 1592
Location: Andromeda Galaxy

PostPosted: Mon Sep 03, 2012 11:15 am
Reply with quote

I see the file defined in FCT cannot update

Code:
INQ FI(FILEPER)                                             
STATUS:  RESULTS - OVERTYPE TO MODIFY                       
 Fil(FILEPER ) Vsa Ope Ena Rea                     Sha     
        Dsn( AFIA.PER.KSDS.CLUSTER                        )


Should be something like

Code:
INQ FI(FILEPER)                                             
STATUS:  RESULTS - OVERTYPE TO MODIFY                       
 Fil(FILEPER ) Vsa Ope Ena Rea     Upd             Sha     
        Dsn( AFIA.PER.KSDS.CLUSTER                        )


What you can do is do a CEDA ALTER and select the Update as YES and reinstall
Back to top
View user's profile Send private message
yussaf.khan

New User


Joined: 05 Jun 2008
Posts: 7
Location: india

PostPosted: Mon Sep 03, 2012 11:35 am
Reply with quote

thanks for the reply.

yes, the problem is that the FCT is not getting updated. A CEDA VIEW FILE(FILEPER) GROUP.. shows that the file is set up for update (as can be seen from the code I have already pasted earlier). However, trying to install this file gives me the message below:
Code:

                                                                             
  S Install failed because an existing definition for file FILEPER could     
     not be deleted.                                 SYSID=CICS APPLID=CICS 
  INSTALL UNSUCCESSFUL                         TIME:  00.59.13  DATE: 12.247


pls suggest.
Back to top
View user's profile Send private message
Pandora-Box

Global Moderator


Joined: 07 Sep 2006
Posts: 1592
Location: Andromeda Galaxy

PostPosted: Mon Sep 03, 2012 11:38 am
Reply with quote

If you did an alter of the file INSTALL is necessary

Also you should be able to change it in CEMT I FILE() option itself then INSTALL is not needed
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Mon Sep 03, 2012 11:38 am
Reply with quote

RTFM about deleting and installing Files in CICS.
Back to top
View user's profile Send private message
yussaf.khan

New User


Joined: 05 Jun 2008
Posts: 7
Location: india

PostPosted: Mon Sep 03, 2012 11:52 am
Reply with quote

OK, I have deleted the file from my group and recreated the resource definition. I, however, still see that the CEMT INQ on this file shows as
Code:

I FI(FILEPER)                                               
STATUS:  RESULTS - OVERTYPE TO MODIFY                       
 Fil(FILEPER ) Vsa Ope Ena Rea                     Sha     
        Dsn( AFIA.PER.KSDS.CLUSTER                        )

Iam not sure why the FCT is not getting updated...given that an INSTALL is not required. pls suggest.
Back to top
View user's profile Send private message
Pandora-Box

Global Moderator


Joined: 07 Sep 2006
Posts: 1592
Location: Andromeda Galaxy

PostPosted: Mon Sep 03, 2012 11:56 am
Reply with quote

Unless you dont install you wont see proper definitions
Back to top
View user's profile Send private message
yussaf.khan

New User


Joined: 05 Jun 2008
Posts: 7
Location: india

PostPosted: Mon Sep 03, 2012 4:54 pm
Reply with quote

I had to close the file first by CEMT SET FILE(filename) CLOSED
for the file INSTALL to work. I now see that the FCT has been updated as desired.
Code:

INQ FI(FILEPER)                                       
STATUS:  RESULTS - OVERTYPE TO MODIFY                 
 Fil(FILEPER ) Vsa Clo Ena Rea Upd Add Bro Del     Old

Pandora-box, you were also correct when you stated that the CEMT INQ FI(filename) could also be used to update the FCT without a CEDA INSTALL.

Thanks for the help!
Back to top
View user's profile Send private message
yussaf.khan

New User


Joined: 05 Jun 2008
Posts: 7
Location: india

PostPosted: Mon Sep 03, 2012 8:41 pm
Reply with quote

running the program/TRAN now gives EIBRESP=19 (file not open), EIBRESP2=60 (MAXFLENGTH value negative, or greater than MAXFLENGTH value for pool). The file status before run is:
Code:

I FI(FILEPER)                                           
STATUS:  RESULTS - OVERTYPE TO MODIFY                   
 Fil(FILEPER ) Vsa Clo Ena Rea Upd Add Bro Del     Old   

This VSAM, as seen above, is closed + enabled and has been defined with 'opentime'=Firstref. It does not have to be opened (explicitly) before the TRAN invocation either, as the CICS version at my shop is 2.3. This is because CICS verions 1.7 or later would automatically open a closed file on encountering the first file operation in the program.

I need help to understand why the file is not getting opened up.
Back to top
View user's profile Send private message
yussaf.khan

New User


Joined: 05 Jun 2008
Posts: 7
Location: india

PostPosted: Mon Sep 03, 2012 9:10 pm
Reply with quote

I had a look at the variable list when carrying out the CEMT SET FI(filename) and observed that the DSNAME field 'value' was in error. Correcting this value resolved the EIBRESP=19.
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8696
Location: Dubuque, Iowa, USA

PostPosted: Mon Sep 03, 2012 9:14 pm
Reply with quote

Did you try to open the file using CEMT? What happened?

Quote:
I need help to understand why the file is not getting opened up.
If the CICS definition does not match in some way the physical file definition, the file won't open in CICS.
Back to top
View user's profile Send private message
yussaf.khan

New User


Joined: 05 Jun 2008
Posts: 7
Location: india

PostPosted: Tue Sep 04, 2012 11:15 am
Reply with quote

CEMT..OPEN would be a good starting point for debug, as you suggest. This was failing for me but it was just a coincidence that I opened the variable list (PF5) when attempting a CEMT SET FI(..) and found that the CICS definition was incorrect for DSNAME.

Thanks (for the support)
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> CICS

 


Similar Topics
Topic Forum Replies
No new posts HILITE on Browse mode? TSO/ISPF 2
No new posts Replace each space in cobol string wi... COBOL Programming 3
No new posts Using API Gateway from CICS program CICS 0
No new posts COBOL -Linkage Section-Case Sensitive COBOL Programming 1
No new posts COBOL ZOS Web Enablement Toolkit HTTP... COBOL Programming 0
Search our Forums:

Back to Top