View previous topic :: View next topic |
Author |
Message |
kingo Intermediate
Joined: 01 Sep 2006 Posts: 167 Topics: 40 Location: chennai
|
Posted: Fri Sep 05, 2008 3:23 am Post subject: SAR |
|
|
Hi,
Is it possible to populate multiple job details from SAR to a dataset?
If so how would I do it?
Regards,
Kingo _________________ IF YOU ARE NOT FOCUSSED ON GOAL ALL YOU SEE IS OBSTACLE. |
|
Back to top |
|
|
tcurrier Intermediate
Joined: 10 Feb 2006 Posts: 188 Topics: 68
|
Posted: Sun Sep 07, 2008 8:10 am Post subject: |
|
|
You would have to hard code the job names, but here is an example of a job that I have :
Code: | //STEP10 EXEC PGM=SARBCH,PARM='K9490P0.SAR41'
//SYSPRINT DD SYSOUT=*,DCB=BLKSIZE=1210
//FILEOUT DD DSN=H2501S.T.TC.SARS,DISP=MOD
//SYSIN DD *
/PRINT ID=H2501ACP DDNAME=FILEOUT
/PRINT ID=H2501AEP DDNAME=FILEOUT
/PRINT ID=H2501AHP DDNAME=FILEOUT
/PRINT ID=H2501AJP DDNAME=FILEOUT
/PRINT ID=H2501ALP DDNAME=FILEOUT
/PRINT ID=H2501APP DDNAME=FILEOUT
/PRINT ID=H2501ARP DDNAME=FILEOUT
/PRINT ID=H2501A0P DDNAME=FILEOUT
/*
// |
|
|
Back to top |
|
|
kingo Intermediate
Joined: 01 Sep 2006 Posts: 167 Topics: 40 Location: chennai
|
Posted: Mon Sep 08, 2008 3:02 am Post subject: |
|
|
Hi Tcurrier,
When I modified like above format I am able to capture only the last job and not the whole list.
Regards,
Kingo _________________ IF YOU ARE NOT FOCUSSED ON GOAL ALL YOU SEE IS OBSTACLE. |
|
Back to top |
|
|
tcurrier Intermediate
Joined: 10 Feb 2006 Posts: 188 Topics: 68
|
Posted: Mon Sep 08, 2008 6:19 am Post subject: |
|
|
If you are not pre-allocating your output file (FILEOUT), you need to do
so. Try putting this step before the SAR print step :
Code: | //*************************************************
//* ALLOCATE FILE
//*************************************************
//STEP05 EXEC PGM=IEFBR14
//SYSPRINT DD SYSOUT=*
//SYSOUT DD SYSOUT=*
//DD1 DD DSN=H2501S.T.TC.SARS,
// DISP=(,CATLG,DELETE),
// MGMTCLAS=WORKM,
// SPACE=(CYL,(10,5),RLSE),
// DCB=(RECFM=FB,LRECL=133,BLKSIZE=1330) |
I tried it and I got the same result that you did (only the last sysout), if
I didn't pre-allocate the output file. |
|
Back to top |
|
|
kolusu Site Admin
Joined: 26 Nov 2002 Posts: 12375 Topics: 75 Location: San Jose
|
Posted: Mon Sep 08, 2008 10:17 am Post subject: |
|
|
kingo wrote: | Hi Tcurrier,
When I modified like above format I am able to capture only the last job and not the whole list.
|
Pay attention to the DISP parameter of the output dataset. You probably had disp=new. Since you are appending the job history you need DISP=MOD
Kolusu |
|
Back to top |
|
|
kingo Intermediate
Joined: 01 Sep 2006 Posts: 167 Topics: 40 Location: chennai
|
Posted: Mon Sep 08, 2008 12:10 pm Post subject: |
|
|
Yes Kolusu I did that and I was about to share the results.
Changing
DISP=MOD
got me the desired results
Thanks tcurrier and Kolusu
Regards,
Kingo _________________ IF YOU ARE NOT FOCUSSED ON GOAL ALL YOU SEE IS OBSTACLE. |
|
Back to top |
|
|
|
|