MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Call a CLIST thru JCL?

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> TSO and ISPF
View previous topic :: View next topic  
Author Message
Pudah
Beginner


Joined: 20 Jun 2003
Posts: 27
Topics: 8
Location: East of the Rock, West of the Hard Place

PostPosted: Sat Jan 03, 2004 4:36 pm    Post subject: Call a CLIST thru JCL? Reply with quote

Is it possible to call a CLIST from within JCL? If so, can any of you point me to documentation on doing so or provide me with an example? Thanks.
Back to top
View user's profile Send private message Send e-mail
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12378
Topics: 75
Location: San Jose

PostPosted: Sun Jan 04, 2004 11:55 am    Post subject: Reply with quote

pudah,

Code:

//STEP0100 EXEC PGM=IKJEFT01,DYNAMNBR=30
//SYSPROC  DD DSN=YOUR CLIST PDS,
//            DISP=SHR
//SYSEXEC  DD DSN=YOUR REXX PDS,
//            DISP=SHR
//SYSTSPRT DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
//SYSUDUMP DD SYSOUT=*
//SYSTSIN DD *
%CLISTNAME  <=== your clist name to be executed
/*


I also coded to execute Rexx execs. They can also be executed from DDname SYSPROC, but the first line of the Rexx must be a comment which contains REXX. You can also use IKJEFT1B, another variant of the TSO command processor which passes return codes/ABENDS back to the jobstream. If you want the return codes to be masked, you could use IKJEFT01.

Hope this helps...

cheers

kolusu
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Pudah
Beginner


Joined: 20 Jun 2003
Posts: 27
Topics: 8
Location: East of the Rock, West of the Hard Place

PostPosted: Mon Jan 05, 2004 8:21 am    Post subject: Reply with quote

Thanks Kolusu. But that seems only to work with CLISTs that can be executed from the READY prompt. The one that I was trying to call cannot be.
Back to top
View user's profile Send private message Send e-mail
Dibakar
Advanced


Joined: 02 Dec 2002
Posts: 700
Topics: 63
Location: USA

PostPosted: Wed Jan 07, 2004 7:50 am    Post subject: Reply with quote

Hi Pudah,

How do you execute the CLIST?

Regards,
Diba.
Back to top
View user's profile Send private message Send e-mail
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12378
Topics: 75
Location: San Jose

PostPosted: Wed Jan 07, 2004 8:24 am    Post subject: Reply with quote

Pudah,

Do you have any ISPF commands in your CLIST? When you say it is not working, can you post the error messages?

Thanks

Kolusu
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Pudah
Beginner


Joined: 20 Jun 2003
Posts: 27
Topics: 8
Location: East of the Rock, West of the Hard Place

PostPosted: Wed Jan 07, 2004 9:07 am    Post subject: Reply with quote

There is an ISPEXEC command in the CLIST. If I run it from the READY prompt, I get an error message that says:

ISPS118L SERVICE NOT INVOKED. A VALID ISPF ENVIRONMENT DOES NOT EXIST.

What the CLIST is doing is executing the Librarian move/copy utility to copy source from Librarian to a PDS, keeping dataset statistics intact. There are other methods to copy source from Librarian to a PDS via JCL, but the methods that I have tried do not leave the stats intact.

It is not absolutely critical that I be able to do this via JCL, I just thought it might be more convenient if it was possible, as I need to do it in between running other jobs.
Back to top
View user's profile Send private message Send e-mail
taltyman
JCL Forum Moderator
JCL Forum Moderator


Joined: 02 Dec 2002
Posts: 310
Topics: 8
Location: Texas

PostPosted: Wed Jan 07, 2004 2:35 pm    Post subject: Reply with quote

From ISPF enter DDLIST on the ===> command line. Then enter SAVE. That will put you in a dataset that is a clist (that can be executed) that will have all your allocated DDs and dataset names... Or you can use that to build out your JCL.
Back to top
View user's profile Send private message
Sreejith
Intermediate


Joined: 02 Dec 2002
Posts: 155
Topics: 25
Location: N.Ireland

PostPosted: Mon Jul 05, 2010 10:35 am    Post subject: Reply with quote

I vaguely remember using a wrapper JCL to execute CLIST instead of storing it in sysproc and then doing execute . Something like following. But can't get it working

Is there a wrapper JCL to execute CLIST or am I just day dreaming ?

Code:

//STEP0100 EXEC PGM=IKJEFT01,DYNAMNBR=30
//SYSPROC  DD DSN=MY.USERID.CLIST,
//            DISP=SHR
//SYSEXEC  DD DSN=MY.USERID.CLIST,
//            DISP=SHR
//SYSTSPRT DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
//SYSUDUMP DD SYSOUT=*
//SYSTSIN DD *
PROC 0
SET AS=&SYSDSN('MY.USERID.TXN.XML')
IF &AS=OK THEN SET RC=7
END
/*
Back to top
View user's profile Send private message Send e-mail Yahoo Messenger
expat
Intermediate


Joined: 01 Mar 2007
Posts: 475
Topics: 9
Location: Welsh Wales

PostPosted: Tue Jul 06, 2010 1:25 am    Post subject: Reply with quote

taltyman wrote:
From ISPF enter DDLIST on the ===> command line. Then enter SAVE. That will put you in a dataset that is a clist (that can be executed) that will have all your allocated DDs and dataset names... Or you can use that to build out your JCL.

Nice one. Appreciated.
_________________
If it's true that we are here to help others,
then what exactly are the others here for ?
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> TSO and ISPF All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
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


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group