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

How to avoid "VSAM OPEN RETURN CODE IS 168"


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Select-mf

New User


Joined: 11 May 2007
Posts: 42
Location: bangalore

PostPosted: Fri Jul 25, 2008 8:15 am
Reply with quote

Hi,

One of my jobs has been abended on a daily basis due to the following return code : "VSAM OPEN RETURN CODE IS 168"

In my JCL, we have a step02 which uses this command :

CEMT SET FI(DD) CLO DIS

Step03 having the command :

VERIFY FILE(DD)

I am getting abend in step03 always. In order to rectify the error, I am going in CICS screen and issue these commands :

CEMT I FILE (DD) CLO DIS
CEMT I FILE (DD) OPE ENA

and come out of the CICS screen. Then, again I am starting the job from step03 and it works fine.

How can I avoid repeating the same task always? Is there any way in JCL itself which I can code to avoid this error without going in CICS screen?
Back to top
View user's profile Send private message
Garry Carroll

Senior Member


Joined: 08 May 2006
Posts: 1193
Location: Dublin, Ireland

PostPosted: Fri Jul 25, 2008 1:02 pm
Reply with quote

Have you any delay between STEP02 and STEP03? In all likelihood, the VERIFY in STEP03 is executing before CICS has completed the CLOSE in STEP02.

Garry.
Back to top
View user's profile Send private message
Select-mf

New User


Joined: 11 May 2007
Posts: 42
Location: bangalore

PostPosted: Fri Jul 25, 2008 2:27 pm
Reply with quote

Hi,

What you say can be correct.
I am not sure there is any delay inbetween step2 and step3.
If that is case also, how can I overcome of it?

Thanks
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1702
Location: Australia

PostPosted: Fri Jul 25, 2008 2:45 pm
Reply with quote

How is your job currently run ? manually or via a scheduling tool ?



Gerry
Back to top
View user's profile Send private message
Garry Carroll

Senior Member


Joined: 08 May 2006
Posts: 1193
Location: Dublin, Ireland

PostPosted: Fri Jul 25, 2008 2:46 pm
Reply with quote

Hi,
Insert a step between which will cause a delay. This might be an Assembler program which issues STIMER WAIT,BINTVL=WAITTIME , or something that does some processing that is not dependent on the CICS file being closed.

Alternatively, make two jobs and have your scheduling package cause the delay.

To see if the idea is correct, try running the steps manually in two separate jobs. Submit the CLOSE first and, when you see it finished, submit the other job.

Regards,
Garry.
Back to top
View user's profile Send private message
Select-mf

New User


Joined: 11 May 2007
Posts: 42
Location: bangalore

PostPosted: Mon Jul 28, 2008 9:03 pm
Reply with quote

This is a scheduled job. We are using CA-7 for this.

Thanks.
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1702
Location: Australia

PostPosted: Tue Jul 29, 2008 5:16 am
Reply with quote

Hi,

I'm sure CA-7 has a Batch Interface utility which you can use to delay STEP03 from starting immediately after STEP02 has completed just as Garry suggested earlier.

It's a long time since I've used CA7 or I should say UCC7


Gerry
Back to top
View user's profile Send private message
Select-mf

New User


Joined: 11 May 2007
Posts: 42
Location: bangalore

PostPosted: Wed Jul 30, 2008 11:23 pm
Reply with quote

Can any one tell me what exactly I have to code in between the step2 and step3 so that step3 will be delayed.

Or if some batch interface utility in CA-7 can be used to delay step3 as what gcicchet mentioned.

Please mention the code or how to use the utility will be helpful for me.

Thanks.
Back to top
View user's profile Send private message
gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1702
Location: Australia

PostPosted: Thu Jul 31, 2008 4:15 am
Reply with quote

Hi,

why not talk to your schedulers, they should be able to assist.


Gerry
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Thu Jul 31, 2008 5:50 am
Reply with quote

Hello,

Do keep in mind that you have a scheduling opportunity rather than a jcl opportunity. . .
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Thu Jul 31, 2008 11:48 am
Reply with quote

Select-mf wrote:
Can any one tell me what exactly I have to code in between the step2 and step3 so that step3 will be delayed.
Or if some batch interface utility in CA-7 can be used to delay step3 as what gcicchet mentioned.
Please mention the code or how to use the utility will be helpful for me.
Thanks.

As I seem to be saying more and more recently, this is a help forum rather than a 'get it done for free' forum. The responses to your thread are good ones, but have unfortunately left you with some work to do.

Do you not believe that your time would be better spent following the leads given rather than asking a complete solution be provided ?
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


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

PostPosted: Thu Jul 31, 2008 11:54 am
Reply with quote

Quote:

rather than asking a complete solution be provided ?


which will lead to even more questions.
Back to top
View user's profile Send private message
Select-mf

New User


Joined: 11 May 2007
Posts: 42
Location: bangalore

PostPosted: Thu Jul 31, 2008 6:45 pm
Reply with quote

Pardon me replying late.

Thanks for the information provided.
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 -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts run rexx code with jcl CLIST & REXX 15
No new posts Compile rexx code with jcl CLIST & REXX 6
No new posts Access to non cataloged VSAM file JCL & VSAM 18
No new posts PuTTY - "User is not a surrogate... IBM Tools 5
No new posts Return codes-Normal & Abnormal te... JCL & VSAM 7
Search our Forums:

Back to Top