Focal Point Banner


As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only.

Join the TIBCO Community
TIBCO Community is a collaborative space for users to share knowledge and support one another in making the best use of TIBCO products and services. There are several TIBCO WebFOCUS resources in the community.

  • From the Home page, select Predict: WebFOCUS to view articles, questions, and trending articles.
  • Select Products from the top navigation bar, scroll, and then select the TIBCO WebFOCUS product page to view product overview, articles, and discussions.
  • Request access to the private WebFOCUS User Group (login required) to network with fellow members.

Former myibi community members should have received an email on 8/3/22 to activate their user accounts to join the community. Check your Spam folder for the email. Please get in touch with us at community@tibco.com for further assistance. Reference the community FAQ to learn more about the community.


Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     Report Caster job to wait on mainframe job [SOLVED]

Read-Only Read-Only Topic
Go
Search
Notify
Tools
Report Caster job to wait on mainframe job [SOLVED]
 Login/Join
 
Member
posted
Hi,


I need to generate lot of reports through webfocus daily after the successfully completion of batch jobs in mainframes. So, I scheduled the reports accordingly in the Report caster. But I also need to verify the successful completion of the mainframe batch job running through ZEKE scheduler.

So, is it possible to identify the mainframe job completion either from webfocus(through Managed Reporting) or from Report Caster.

Please post your suggestions ASAP.

Thanks in Advance.

This message has been edited. Last edited by: Amar,


WebFOCUS 7.6.4, Mainframe Focus
Mainframe / Z/OS,MVS
Managed Reporting / Windows
All formats
 
Posts: 14 | Registered: July 26, 2011Report This Post
<JG>
posted
have the mainframe batch jobs write a file with a staus date in it as part of the process.

The caster jobs can check this file as pre processing step and using a combination of a loop and SLEEP
can effectivly pause the Caster job until the data is available.
 
Report This Post
Master
posted Hide Post
quote:
Originally posted by JG:
have the mainframe batch jobs write a file with a staus date in it as part of the process.

The caster jobs can check this file as pre processing step and using a combination of a loop and SLEEP
can effectivly pause the Caster job until the data is available.


+1. Similar to what we do.

- ABT


------------------------------------
WF Environment:
------------------------------------
Server/Client, ReportCaster, Dev Studio: 7.6.11
Resource Analyzer, Resource Governor, Library, Maintain, InfoAssist
OS: Windows Server 2003
Application/Web Server: Tomcat 5.5.25
Java: JDK 1.6.0_03
Authentication: LDAP, MRREALM Driver
Output: PDF, EXL2K, HTM

------------------------------------
Databases:
------------------------------------
Oracle 10g
DB2 (AS/400)
MSSQL Server 2005
Access/FoxPro
 
Posts: 561 | Registered: February 03, 2010Report This Post
Member
posted Hide Post
Thanks JG and ABT for your response.

I will try to check if any file is generated with a status date.

Is it possible to provide a sample code for using LOOP and SLEEP to check the data availability? Because I never tried this before.

Thanks in advance.


WebFOCUS 7.6.4, Mainframe Focus
Mainframe / Z/OS,MVS
Managed Reporting / Windows
All formats
 
Posts: 14 | Registered: July 26, 2011Report This Post
<JG>
posted
If you cannot read the staus then it will not work.

If you can confirm that you can read it, then I and lots of others will help you with a solution.
 
Report This Post
Master
posted Hide Post
In our example, the program reads a table for a trigger date (this would be comparable to JG's text file). This is an include to a job scheduled daily and monthly in ReportCaster. We expect that the load job will be done before the job that uses this code, but if not, it will wait around for an hour before dieing.

PB is Periods Back and is a table that holds various important dates formatted for ease of use. PB = 1 is yesterday.

When the dates are the same, the routine just falls through to the next statement and back to the including program.

The job is killed via &KILL_RPC.

-ABT


-SET &CNTR = 0;
-*---------------------------------------------------------
-LOOP
-*FIND LAST DATE THE ATB EXTRACT WAS UPDATED
TABLE FILE DMVALUES
SUM MAX.VSTART
WHERE VINDICATOR EQ 'ATBXDONE'
ON TABLE HOLD AS ASATBDT1
END


DEFINE FILE ASATBDT1
LASTDATE/YYMD = HDATE(VSTART, 'YYMD');
END

TABLE FILE ASATBDT1
PRINT
LASTDATE
BY VSTART NOPRINT
ON TABLE HOLD AS ASATBDT2 FORMAT ALPHA
END

-RUN
-READ ASATBDT2 &LASTDATE.A8.
-RUN


-*---------------------------------------------------------
-*DETERMINE THE LAST MONTH END DATE
-SET &PB=1;

-*NOTE:  PRE-PROCESSING PROCEDURES HAVE TO RESIDE IN THE STANDARDS FOLDER.
-*THEREFORE WE DON'T NEED THE -MRNOEDIT WITH THE -INCLUDE SDRYYMD BECAUSE
-*SDRYYMD IS IN THE SAME DOMAIN.
-INCLUDE SDRYYMD
-SET &ENDM = &ENDMTH_YYMD;

-*COMPARE THE LAST DAT THE ATB EXTRACT WAS UPDATED AND THE LAST MONTH END DATE
-*IF THEY ARE THE SAME PROCESSING OF THE REPORT JOB WILL CONTINUE,
-*IF NOT THE JOB WILL SLEEP (OR EVENTUALLY END WITHOUT RUNNING THE REPORT)
-SET &DATESSAME = IF &LASTDATE EQ &ENDM THEN 'Y' ELSE 'N';
-IF &DATESSAME EQ 'Y' GOTO YESDATE ELSE GOTO NODATE;

-*---------------------------------------------------------

-NODATE

-SET &CNTR = &CNTR + 1;
SLEEP 900
-RUN

-IF &CNTR GE 4 GOTO KILLME;
-GOTO LOOP

-*---------------------------------------------------------

-KILLME
-SET &&KILL_RPC = 'Y';
-TYPE 'JOB KILLED AFTER SLEEPING FOR 1 HOUR (4 * 900 SECONDS) (LOOPS=&CNTR)
-TYPE 'RERUN MANUALLY WHEN ATB EXTRACT IS COMPLETE'
-GOTO THEEND

-*---------------------------------------------------------

-YESDATE
-TYPE "DATES ARE THE SAME"
-GOTO THEEND
-THEEND
-EXIT


------------------------------------
WF Environment:
------------------------------------
Server/Client, ReportCaster, Dev Studio: 7.6.11
Resource Analyzer, Resource Governor, Library, Maintain, InfoAssist
OS: Windows Server 2003
Application/Web Server: Tomcat 5.5.25
Java: JDK 1.6.0_03
Authentication: LDAP, MRREALM Driver
Output: PDF, EXL2K, HTM

------------------------------------
Databases:
------------------------------------
Oracle 10g
DB2 (AS/400)
MSSQL Server 2005
Access/FoxPro
 
Posts: 561 | Registered: February 03, 2010Report This Post
Member
posted Hide Post
Hello ABT

Thank you so much for your response. I will try and let you know if I encounter any problem.


Hi JG

I do have a GDG in the batch process which generates a sequence number incremented by 1 daily after the batch completion(It is the last batch job). It will reset to one once it reaches the count to 999.


One more question is, is it possible to trigger 5 report caster jobs after completion of first report caster job.

Ex: I scheduled first report caster job at 8.00 AM. After the completion of this first job, I need to trigger 5 more jobs irrespective of timing.


WebFOCUS 7.6.4, Mainframe Focus
Mainframe / Z/OS,MVS
Managed Reporting / Windows
All formats
 
Posts: 14 | Registered: July 26, 2011Report This Post
Master
posted Hide Post
quote:
One more question is, is it possible to trigger 5 report caster jobs after completion of first report caster job.

Ex: I scheduled first report caster job at 8.00 AM. After the completion of this first job, I need to trigger 5 more jobs irrespective of timing.


3 ways come to mind:
- Created the other 5 jobs as tasks of the first. If you need to achieve flow control (only execute this job if this condition is met), you may need to use a separate table/file to read status.

- Create 'Post Processing' procedures. ReportCaster: Tasks > Edit > Advanced > Procedures > Post Processing Procedure (1 and 2). You can only do 2, but they will execute after completion.

- As a final step to the main job, use -INCLUDEs to reference the other 5. You can also use conditionals here to smartly control flow. This approach can also be used in the second case to reference a master job (with 5 subs) as a Post Procedure.

- ABT


------------------------------------
WF Environment:
------------------------------------
Server/Client, ReportCaster, Dev Studio: 7.6.11
Resource Analyzer, Resource Governor, Library, Maintain, InfoAssist
OS: Windows Server 2003
Application/Web Server: Tomcat 5.5.25
Java: JDK 1.6.0_03
Authentication: LDAP, MRREALM Driver
Output: PDF, EXL2K, HTM

------------------------------------
Databases:
------------------------------------
Oracle 10g
DB2 (AS/400)
MSSQL Server 2005
Access/FoxPro
 
Posts: 561 | Registered: February 03, 2010Report This Post
Member
posted Hide Post
Hi ABT,

Thank you very much for your response. The LOOP worked fine for me.

Thanks


WebFOCUS 7.6.4, Mainframe Focus
Mainframe / Z/OS,MVS
Managed Reporting / Windows
All formats
 
Posts: 14 | Registered: July 26, 2011Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     Report Caster job to wait on mainframe job [SOLVED]

Copyright © 1996-2020 Information Builders