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

To write a Job card using CLIST


IBM Mainframe Forums -> TSO/ISPF
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
rakesh pattanayak

New User


Joined: 29 May 2007
Posts: 16
Location: bangalore

PostPosted: Tue Jul 31, 2007 3:48 pm
Reply with quote

Hi All,
i want to write a CLIST Macro which will give the jobcard in a JCL.

lets say if i will type JC then it will write the JOBCARD inside that JCL.

Can anyone please help me?

Thanks,
Rakesh.
Back to top
View user's profile Send private message
expat

Global Moderator


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

PostPosted: Tue Jul 31, 2007 4:45 pm
Reply with quote

You will need to create an ISPF edit macro to do that, and also make sure that it is concatenated into SYSEXEC or SYSPROC of your session to be able to execute it in the way that you want to.
Back to top
View user's profile Send private message
rakesh pattanayak

New User


Joined: 29 May 2007
Posts: 16
Location: bangalore

PostPosted: Tue Jul 31, 2007 4:48 pm
Reply with quote

Yes i know that,
but i want the sample code for that.
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: Tue Jul 31, 2007 7:08 pm
Reply with quote

Hello,

If
Quote:
Yes i know that


then write some code and post here when it abends or you have questions.

One of the main concepts behind the forums is that we provide assistance to help people learn or solve problems - not do their work.
Back to top
View user's profile Send private message
expat

Global Moderator


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

PostPosted: Tue Jul 31, 2007 9:56 pm
Reply with quote

rakesh pattanayak wrote:
Yes i know that,
but i want the sample code for that.


1) What have you tried yourself, and what were the results

2) Sample code supplied upon receipt of payment - current contract rate.
Back to top
View user's profile Send private message
rakesh pattanayak

New User


Joined: 29 May 2007
Posts: 16
Location: bangalore

PostPosted: Wed Aug 01, 2007 5:34 pm
Reply with quote

ISREDIT MACRO
SET SYSMSG=OFF
ISREDIT (SRCLIB) = DATASET
SET SRC = &STR(')&SRCLIB&STR(')
SET LINE = 0
SET OUTSTR = &STR(+
//&SYSUID.J JOB ,,NOTIFY=&&SYSUID,CLASS=D,MSGLEVEL=(1,1),MSGCLASS=X)
ISREDIT LINE_AFTER &LINE = (OUTSTR)
SET LINE = &LINE + 1


this is the code i wrote and when running it is giving me the following error

IKJ56621I INVALID COMMAND NAME SYNTAX
3 *-* SET SYSMSG=OFF
+++ RC(-3) +++
IKJ56621I INVALID COMMAND NAME SYNTAX
4 *-* ISREDIT (SRCLIB) = DATASET
+++ RC(-3) +++
5 +++ SET SRC = &STR(')&SRCLIB&STR(')
IRX0035I Error running JC, line 5: Invalid expression
***
Back to top
View user's profile Send private message
expat

Global Moderator


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

PostPosted: Wed Aug 01, 2007 5:58 pm
Reply with quote

That looks more like CLIST code rather than REXX code.
Back to top
View user's profile Send private message
rakesh pattanayak

New User


Joined: 29 May 2007
Posts: 16
Location: bangalore

PostPosted: Wed Aug 01, 2007 6:02 pm
Reply with quote

YES THAT ONE IS CLIST CODE.

CAN ANYONE TELL ME WHY I AM GETTING THAT ERROR?
Back to top
View user's profile Send private message
superk

Global Moderator


Joined: 26 Apr 2004
Posts: 4652
Location: Raleigh, NC, USA

PostPosted: Wed Aug 01, 2007 6:48 pm
Reply with quote

Odd, that code worked just fine here (z/OS V1R7). If I didn't know better, I'd swear that the messages "+++ RC(-3) +++" are indicating that ISPF Services aren't available.
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: Wed Aug 01, 2007 8:24 pm
Reply with quote

Hello,

What is on your screen when you execute your code that abends?

Are you in an ISPF session or are you possibly running from a native tso session?
Back to top
View user's profile Send private message
rakesh pattanayak

New User


Joined: 29 May 2007
Posts: 16
Location: bangalore

PostPosted: Wed Aug 01, 2007 8:32 pm
Reply with quote

i think i am in ISPF.i am not sure about this .
Code:
                            ISPF Primary Option Menu                           
  Option ===>                                                                   
                                                                               
 0  Settings      Terminal and user parameters            User ID . : T6327RP   
 1  View          Display source data or listings         Time. . . : 10:56     
 2  Edit          Create or change source data            Terminal. : 3278     
 3  Utilities     Perform utility functions               Screen. . : 1         
 4  Foreground    Interactive language processing         Language. : ENGLISH   
 5  Batch         Submit job for language processing      Appl ID . : ISR       
 6  Command       Enter TSO or Workstation commands       TSO logon : TSOUSER   
 7  Dialog Test   Perform dialog testing                  TSO prefix: T6327RP   
 8  LM Facility   LMF has been withdrawn by IBM          System ID : D10A     
 9  IBM Products  IBM program development products       MVS acct. : 0,1723   
 10 SCLM          SW Configuration Library Manager       Release . : ISPF 5.8 
 11 Workplace     ISPF Object/Action Workplace                               
 S  SDSF          System Display and Search Facility                           
 V  APPL Menu     Application development Tools Menu                           
                                                                               
    Site: DVDC-D10A  z/OS   01.08.00   PDF 5.8                                 
                                                                               
                                                                               
      Enter X to Terminate using log/list defaults                             
[/url]
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: Wed Aug 01, 2007 8:50 pm
Reply with quote

Hello,

Quote:
i think i am in ISPF
I think so too icon_smile.gif

Have you another/similar clist that works successfully from the same command area?
Back to top
View user's profile Send private message
mmwife

Super Moderator


Joined: 30 May 2003
Posts: 1592

PostPosted: Wed Aug 01, 2007 11:34 pm
Reply with quote

But you may not be in Kansas anymore. icon_smile.gif

What I do is create a jobcard in my JCL pds (I call it "J") and when I complete the rest of my JCL I copy J before the 1st line.

Simpler than a CLIST or Macro.
Back to top
View user's profile Send private message
Douglas Wilder

Active User


Joined: 28 Nov 2006
Posts: 305
Location: Deerfield IL

PostPosted: Thu Aug 02, 2007 12:05 am
Reply with quote

I got the same error you got when I put it in my Rexx.Exec library (allocated to DD SYSEXEC). When I put it in my Clist library (concatenated to DD SYSPROC) it worked ok.

You must execute it when in ISPF edit on your JCL of course.
Back to top
View user's profile Send private message
rakesh pattanayak

New User


Joined: 29 May 2007
Posts: 16
Location: bangalore

PostPosted: Thu Aug 02, 2007 9:53 am
Reply with quote

Thanks a lot.
actually the code is a CLIST and all CLIST PDS we need to conactenate to SYSPROC


it worked for me.

Thanks a ton again.
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 -> TSO/ISPF

 


Similar Topics
Topic Forum Replies
No new posts Compare 2 files(F1 & F2) and writ... JCL & VSAM 8
No new posts Write line by line from two files DFSORT/ICETOOL 7
No new posts JCL sort card - get first day and las... JCL & VSAM 9
No new posts CLIST - Virtual storage allocation error CLIST & REXX 5
This topic is locked: you cannot edit posts or make replies. How To Write, Compile and Execute Cob... COBOL Programming 5
Search our Forums:

Back to Top