View previous topic :: View next topic
|
Author |
Message |
arijit_ghosh86
New User
Joined: 18 Sep 2010 Posts: 7 Location: Kolkata
|
|
|
|
Hi All,
I have aproblem..
the senerio is like that supoose a job XYZ runs everyday i.e. 5 days a wk
on the saturday i need to create a report.
I know how SARBCH works, I want to download all 5 days sar details of the job XYZ in a single dataset or , is it possible to download report from SAR using SARBCH if i provide jobid ?? |
|
Back to top |
|
|
vasanthz
Global Moderator
Joined: 28 Aug 2007 Posts: 1742 Location: Tirupur, India
|
|
|
|
Hello,
You could try GEN=-N parameter for SARBCH.
Code: |
//JS020 EXEC PGM=SARBCH,PARM='SAR.DATABASE'
//SYSPRINT DD SYSOUT=*
//REPORT DD SYSOUT=*
//SYSUDUMP DD SYSOUT=*
//SARSTUFF DD DSN=WELLS.SAROUT,DISP=MOD
//SYSIN DD *
/DBASE NAME=SAR.DATABASE
/LOAD ID=JOBNAME DDNAME=SARSTUFF GEN=-0
/LOAD ID=JOBNAME DDNAME=SARSTUFF GEN=-1
/LOAD ID=JOBNAME DDNAME=SARSTUFF GEN=-2
/LOAD ID=JOBNAME DDNAME=SARSTUFF GEN=-3
/LOAD ID=JOBNAME DDNAME=SARSTUFF GEN=-4
/* |
This would fetch last 5 runs of the job. Its safe to retrieve atleast 10 generation of the job and then filtering out the required 5 set of jobs as the job might have abended on one day and you would have data for only 4 days effectively.
Note: DISP=MOD
Hope it helps. |
|
Back to top |
|
|
arijit_ghosh86
New User
Joined: 18 Sep 2010 Posts: 7 Location: Kolkata
|
|
|
|
thnx for the response but its not working...
"Requested sysout not found in master index"
/PRINT ID=XYZ DDNAME=***** GEN=-1
[XYZ is the job name and ****=DD NAME]
I also used it with LOAD ID...its not working too. |
|
Back to top |
|
|
vasanthz
Global Moderator
Joined: 28 Aug 2007 Posts: 1742 Location: Tirupur, India
|
|
|
|
Hello,
Have you verified that your job XYZ exists in SAR & has atleast two generations of it? |
|
Back to top |
|
|
vasanthz
Global Moderator
Joined: 28 Aug 2007 Posts: 1742 Location: Tirupur, India
|
|
|
|
When a job that is not present in SAR is requested via the LOAD statement, the error message from SARBCH is
Code: |
SARBCL10 Requested sysout not found in master index |
|
|
Back to top |
|
|
arijit_ghosh86
New User
Joined: 18 Sep 2010 Posts: 7 Location: Kolkata
|
|
|
|
@Vasanth..yes Sir !
I have checked it.
But its not possible i guess... |
|
Back to top |
|
|
vasanthz
Global Moderator
Joined: 28 Aug 2007 Posts: 1742 Location: Tirupur, India
|
|
|
|
Quote: |
I know how SARBCH works, |
Have you tried running SARBCH earlier and got it to work?
The values in
Code: |
//JS020 EXEC PGM=SARBCH,PARM='SAR.DATABASE' |
Code: |
/DBASE NAME=SAR.DATABASE |
are site specific. have you mentioned the correct database names in these two cards? |
|
Back to top |
|
|
arijit_ghosh86
New User
Joined: 18 Sep 2010 Posts: 7 Location: Kolkata
|
|
|
|
thanks for replying Vasanth...the ans is YES.
I told you that i can access it /PRINT ID=<JOBNAME> DDNAME=<DDNAME>
but supoose i have 5 entries are their with SYSout ID XYZ.
i wan to download the total SAR output of all 5 entries in single file at a time. |
|
Back to top |
|
|
vasanthz
Global Moderator
Joined: 28 Aug 2007 Posts: 1742 Location: Tirupur, India
|
|
|
|
"My guess" is that if the job is currently running in SPOOL then GEN=-0 would fail. I would like to be corrected if this statement is incorrect.
If the job is completed then latest generation can be accessed by GEN=-0.
If its in execution status then GEN=-1 will get you latest generation from SAR.
The CA View manual does not say anything about relative numbers for GEN when job is running currently. |
|
Back to top |
|
|
dbzTHEdinosauer
Global Moderator
Joined: 20 Oct 2006 Posts: 6966 Location: porcelain throne
|
|
|
|
Quote: |
The CA View manual does not say anything about relative numbers for GEN when job is running currently.
|
don't know about SAR, but within the job +1 is the gen number for current generation - until job is ended.
and, i don't know why -0 is used instead of 0? |
|
Back to top |
|
|
vasanthz
Global Moderator
Joined: 28 Aug 2007 Posts: 1742 Location: Tirupur, India
|
|
|
|
Hello Dick,
By 'generations' I was referring to SAR generations of job entries on CA-view as opposed to GDG generations. They both have same terminology but two different things. |
|
Back to top |
|
|
|