View previous topic :: View next topic
|
Author |
Message |
thesumitk
Active User
Joined: 24 May 2013 Posts: 156 Location: INDIA
|
|
|
|
Hi ,
I am in process to automate one manual process which we do each day , We takes a rport from Sar (run time of few jobs) and report them in to an email.. I am trying to run a Rexx code whihc would do this automatically ..
I see one post from SANT532 , he mentioned the below code can invoke sar
Code: |
OPT = "M;SAR;=S XXXXXXXX"
ADDRESS ISPEXEC "SELECT PGM(ISPSTRT) SUSPEND PARM(&OPT)"
ADDRESS TSO |
This code is working fine and invoking the sar screen but then it needs a PF3 to come back to rexx control again...
I need to take the run time of the jobs and I will chek in Rexx if the run time is for today's run or not, there after send an email with details of all the jobs.
Please help me getting the values from SAR panel.. |
|
Back to top |
|
|
Pandora-Box
Global Moderator
Joined: 07 Sep 2006 Posts: 1592 Location: Andromeda Galaxy
|
|
|
|
Why not call SAR through Jcl? |
|
Back to top |
|
|
thesumitk
Active User
Joined: 24 May 2013 Posts: 156 Location: INDIA
|
|
|
|
I dont know if I Can get a report for the current day job by JCL ,, I need to provide the genrations or JOBID in JCL which will call SAR ..
I am not sure if there is a way to achieve this thru JCL?
My Requirement is below
I need to check jobs A,B,C,D,E,F have run today or not .. OR.. I take the data from SAR for the current sysout of any job and check in my rexx program for verification...
PLease suggest |
|
Back to top |
|
|
vasanthz
Global Moderator
Joined: 28 Aug 2007 Posts: 1742 Location: Tirupur, India
|
|
|
|
thesumitk,
I once had a same requirement and was not having access to SMF. so I followed the below steps.
1. extract job log from SAR using SARBCH utility. example : www.ibmmainframes.com/viewtopic.php?t=10356&highlight=sarbch
2. Process the extracted job log using REXX or SAS or any other language.
3. We had RACF, so got the job start date from ICH70001I message in joblog. Job start time from $HASP373 message, and job end time from $HASP395.
4. Use the start/end date and time do your processing.
Hope it helps. |
|
Back to top |
|
|
thesumitk
Active User
Joined: 24 May 2013 Posts: 156 Location: INDIA
|
|
|
|
Hi Vasanthz
Thanks for the information!!!
Would you be able to tell me If I can extract only the current record from SAR for My job
For Example .. If job A runs daily at 10:00 Am and I am runing my SAR extract today after completion of job A .. Can I tell my extract job to Fetch only the record for today's run of JOB A?
Thanks in Advance !! |
|
Back to top |
|
|
vasanthz
Global Moderator
Joined: 28 Aug 2007 Posts: 1742 Location: Tirupur, India
|
|
|
|
Hello,
the /PRINT or /LOAD by default would select the most recent run of the job, "that is archived in SAR".
If your job runs at 10:00 AM and if SAR has archived that job in its database then by default GEN=-0 and it chooses the most recent entry for that job.
For some reason if your daily job does not run at 10:00 AM and you to submit SARBCH at say 10:30 AM then SARBCH would get you previous day's run of the job.
If you want conditional processing based on archive date, look at the output returned by /LIST command, and then build your /LOAD or /PRINT statements from /LIST output.
For more info on SARBCH look at Ca-View reference guide
Chapter 10: Batch Processing. |
|
Back to top |
|
|
thesumitk
Active User
Joined: 24 May 2013 Posts: 156 Location: INDIA
|
|
Back to top |
|
|
Robert Sample
Global Moderator
Joined: 06 Jun 2008 Posts: 8697 Location: Dubuque, Iowa, USA
|
|
|
|
If your site is authorized to use CA-View, then you have access to the manauls -- via hard copy, or via internal web site, or via logging into the CA support web site. As these manuals are copyright by CA, nobody on this forum can provide you the manuals nor a link to them. |
|
Back to top |
|
|
vasanthz
Global Moderator
Joined: 28 Aug 2007 Posts: 1742 Location: Tirupur, India
|
|
|
|
Hello,
As Robert said, we cannot share the documentation as it is copyrighted.
Its no big deal to download the manual yourself from
support.ca.com
Go there, register for a free user ID and access the manuals to Ca-View. |
|
Back to top |
|
|
|