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

How to route the JES messages and Job output of a JCL


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
anish.ibm

New User


Joined: 28 Jun 2007
Posts: 23
Location: Bangalore

PostPosted: Wed Jul 04, 2007 10:22 am
Reply with quote

Hi,

Please help me how to route the JES messages and Job output of a JCL to a dataset upon the execution of a same JCL . I dont want this to be done by XDC in the Spool.

Rgds
An
Back to top
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1436
Location: Bangalore,India

PostPosted: Wed Jul 04, 2007 10:25 am
Reply with quote

Anish,

Quote:
Please help me how to route the JES messages and Job output of a JCL to a dataset upon the execution of a same JCL

In the job, include SDSF step as your last step. It automatically takes XDC for the previous steps.
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


Joined: 22 Apr 2006
Posts: 6248
Location: Mumbai, India

PostPosted: Wed Jul 04, 2007 11:20 am
Reply with quote

Quote:
In the job, include SDSF step as your last step.

Murali,

Can you please show the code for above, I didn't get how to do this ?
Back to top
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1436
Location: Bangalore,India

PostPosted: Wed Jul 04, 2007 11:29 am
Reply with quote

Anuj,

Quote:
Can you please show the code for above, I didn't get how to do this ?


Please find sampel step below -

Code:
//SDSFSTEP EXEC PGM=SDSF
//SYSPRINT DD SYSOUT=*
//SYSOUT DD SYSOUT=*
//ISFOUT DD SYSOUT=*
//ISFIN DD  *
PREFIX *
OWNER *
ST yourjobname
++ALL
Find yourjobname last
++S
PRT ODSN 'my.pds(member)'
prt
prt close
END
/*
Back to top
View user's profile Send private message
anish.ibm

New User


Joined: 28 Jun 2007
Posts: 23
Location: Bangalore

PostPosted: Wed Jul 04, 2007 11:38 am
Reply with quote

Thx

Guys

Let me try
Back to top
View user's profile Send private message
V S Amarendra Reddy

Active User


Joined: 13 Sep 2006
Posts: 220
Location: USA

PostPosted: Wed Jul 04, 2007 2:34 pm
Reply with quote

Yup!!!! Its working Buddy but Its truncating the record length to 80 only.. can we get the total sysout without trunacting the record.. I accept its a varible record length...But is there any way to capture that...
Please suggest(Ofcourse I have done it by allocating a dataset with the required record length by checking in the spool and then when I submitted the job no truncation happened)..

But can we automate like dynamically can it take the record lenght and will print it to????

Regards
Amar
Back to top
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1436
Location: Bangalore,India

PostPosted: Wed Jul 04, 2007 2:43 pm
Reply with quote

Amar,

Quote:
Yup!!!! Its working Buddy but Its truncating the record length to 80 only.. can we get the total sysout without trunacting the record.. I accept its a varible record length...But is there any way to capture that...
Please suggest(Ofcourse I have done it by allocating a dataset with the required record length by checking in the spool and then when I submitted the job no truncation happened)..


Either increase your PDS lrecl to 133 or more

OR

Capture it in a flat file.
Back to top
View user's profile Send private message
expat

Global Moderator


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

PostPosted: Wed Jul 04, 2007 3:20 pm
Reply with quote

I think that you will need to look at the SDSF manual and use a PARM to set the screen size to 133 instead of the default 80.
Back to top
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1436
Location: Bangalore,India

PostPosted: Wed Jul 04, 2007 3:24 pm
Reply with quote

Expat,

Quote:
I think that you will need to look at the SDSF manual and use a PARM to set the screen size to 133 instead of the default 80.


I dint get you. The default spool is 133. Isn't it?
Back to top
View user's profile Send private message
expat

Global Moderator


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

PostPosted: Wed Jul 04, 2007 3:44 pm
Reply with quote

Yes, but the default for screen size is only 80 bytes. And what we are doing in batch is simulating an online, i.e. on screen, display.
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


Joined: 22 Apr 2006
Posts: 6248
Location: Mumbai, India

PostPosted: Wed Jul 04, 2007 5:17 pm
Reply with quote

Murali,

Thanks for the code.

I never used the SDSF program for this purpose, so your code gives me some queris to ask.
Let me expleain & ask, what I could percept from your code:
Code:
//SDSFSTEP EXEC PGM=SDSF

EXECcutes the program SDSF.
Code:
//SYSPRINT DD SYSOUT=*

Program messages to be listed, if any.
Code:
//SYSOUT DD SYSOUT=*

System messages to be listed.
Code:
//ISFOUT DD SYSOUT=*

This parameter is for which messages?
Code:
//ISFIN DD  *
PREFIX *
OWNER *
ST yourjobname

In ISPF, if I need to see the statistics of JOBs, I do the following:
START S.ST/PRE 'JOB name'
so in above, why do we make use of ST instead of PRE?
Code:
++ALL

This is for what, is this a delimiter, if yes, what purpose it's serving here. But I think, delimiters are coded in pairs, I can't see any pairing delimiter.
Code:
Find yourjobname last
++S

Same query as for A++ & why the Key word 'last'. Are there some more key-words which can be used here?
Code:
PRT ODSN 'my.pds(member)'

PRT is print.
I believe, ODSN should be read as Out(put)-DSN. If in place of 'my.pds(member)' I give some PS name such as PRT ODSN 'HLQ.SDSF.OUT', it should work. When I tried it, step expects the PS to be already catalogued, it does not generate the new PS. Is it because we can not provide DISP parameter here?
Code:
prt
prt close

What's the significance of above 'prt' here? I doubt this is same as "PRT" used above in PRT ODSN 'my.pds(member)'.
Code:
END
/*

Even if I dont code END, in-stream data delimiter /* will tell the OS to understand the end of in-stream Data or is it a necessary one.

I asked a lot, hopefully I'm not bothering you.
Back to top
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1436
Location: Bangalore,India

PostPosted: Thu Jul 05, 2007 2:02 pm
Reply with quote

Anuj,

Check out the links for you queries-

publib.boulder.ibm.com/cgi-bin/bookmgr/BOOKS/ISF1GR20/CCONTENTS?DT=20000630112315

publib.boulder.ibm.com/cgi-bin/bookmgr/BOOKS/ISFGR10/CCONTENTS?DT=19990709125748
Back to top
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1436
Location: Bangalore,India

PostPosted: Thu Jul 05, 2007 2:09 pm
Reply with quote

Anuj,

To put more -

Go through
Code:
  ISFOUT   SDSFOUT   
in the spool. It actually shows the working of
Code:
//ISFIN DD  *
statements. Hope you will get some answers from this.
Back to top
View user's profile Send private message
a027412

New User


Joined: 05 Jul 2007
Posts: 40
Location: Minneapolis, MN

PostPosted: Mon Jul 09, 2007 2:51 pm
Reply with quote

Murali,
Instead of
Code:
FIND JobName FIRST

Is there way to search with JobName and JobId?
I am asking this cos, users would have sorted their POSN of SPOOL to their convenience.
Back to top
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1436
Location: Bangalore,India

PostPosted: Mon Jul 09, 2007 5:22 pm
Reply with quote

a027412,

FIRST, LAST are the option parameters for FIND. If you remove these, FIND is an equivalent of PRE in the SDSF (i.e., FIND JOBNAME = PRE JOBNAME). For more info on this, refer the links I had provided in my previous post.

Regarding JobId, I have never used it.
Back to top
View user's profile Send private message
a027412

New User


Joined: 05 Jul 2007
Posts: 40
Location: Minneapolis, MN

PostPosted: Mon Jul 09, 2007 5:29 pm
Reply with quote

Murali,
i actually gone thru the manul and found that it can be achived using FILTER command.
Syntax
FILTER Jobid EQ Jobxxxxx

Thanks for your help
[/i]
Back to top
View user's profile Send private message
murmohk1

Senior Member


Joined: 29 Jun 2006
Posts: 1436
Location: Bangalore,India

PostPosted: Mon Jul 09, 2007 5:34 pm
Reply with quote

a027412,

As told before, I have never tried JobId thing. I strongly believe the JCL you had created for filtering job with the jobid is useless for next run (as jobid tends to change). Anyways, just try and let us know.
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 REXX/CMS How to place command console... CLIST & REXX 4
No new posts Reroute print output via REXX/SDSF TSO/ISPF 6
No new posts Concatenate 2 input datasets and give... JCL & VSAM 2
No new posts How to turn off 'ACTION' SDSF output ... TSO/ISPF 2
No new posts TRIM everything from input, output co... DFSORT/ICETOOL 1
Search our Forums:

Back to Top