Focal Point Banner
Community Center Education Summit Technical Support User Groups
Let's Get Social!

Facebook Twitter LinkedIn YouTube
Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED]Run ReportCaster Job Dynamically
Go
New
Search
Notify
Tools
Reply
  
[SOLVED]Run ReportCaster Job Dynamically
 Login/Join
 
Platinum Member
posted
Hi All,

Can we execute ReportCaster job on the basis of database column value.

Thanks

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


WebFocus 8104,8204
Excel/PDF/HTML/HTMLTABLE/XML/ALPHA/GIF file/GRAPH/Active technologies
 
Posts: 182 | Location: INDIA | Registered: July 11, 2013Reply With QuoteReport This Post
Platinum Member
posted Hide Post
In 7.7 (I have no knowledge yet of 8.0) you can start ReportCaster jobs with DSTRUN.
So you can write a separate procedure to test the database column values to check which jobs need to start and then start with DSTRUN.

regards, Martin.


WebFocus 8203M, iWay DataMigrator, Windows, DB2 Windows V10.5, MS SQL Server, Azure SQL, Hyperstage, ReportCaster
 
Posts: 152 | Registered: March 29, 2013Reply With QuoteReport This Post
Expert
posted Hide Post
We have a job that runs jobs based on table contents.

The job is run every (can't remember) minutes.


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.05OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Know The Code

 
Posts: 6104 | Location: Land of the Darug people, Terra Australis Incognita | Registered: October 31, 2006Reply With QuoteReport This Post
Platinum Member
posted Hide Post
Hi, I think you can set up an ALERT. Check the documentation.


Webfocus 8
Windows, Linux
 
Posts: 246 | Location: Palm Coast, FL | Registered: February 05, 2010Reply With QuoteReport This Post
Master
posted Hide Post
DSTRUN works in 8.0 depending on your security set up. It worked for us just fine during testing but when we got security in place it stopped. I still have an open problem report. I believe you can use Restful Web Services as well but we haven't tried that. We have about 40 jobs that are run using DSTRUN and I wrote a substitute routine that updates the next run date/time in ReportCaster. The jobs are set up to run once. Then when I want to run it, I call the routine to set the next run date/time to the current date/time plus 1 minute.


In FOCUS since 1985. Prod WF 8.0.08 (z90/Suse Linux) DB (Oracle 11g), Self Serv, Report Caster, WebServer Intel/Linux.
 
Posts: 919 | Location: Oklahoma City | Registered: October 27, 2006Reply With QuoteReport This Post
Platinum Member
posted Hide Post
Hi jgelona: We also use DSTRUN but we were told to start using RESTFul services.. Is your routine a fex routine? We were creating Access Lists using SQL scripts but no longer can use that..

Thanks


Prod/Dev/Test: WF 8.1.5 on (Windows Server 2012 R2 )
SandBox: WebFocus Server 8.1.5 on Windows Server 2008 R2
WebFOCUS App Studio 8.1.5 and Developer Studio 8.1.5 on Windows 7
 
Posts: 126 | Location: USA | Registered: August 21, 2008Reply With QuoteReport This Post
Platinum Member
posted Hide Post
Thank you all for your response. May I get any tutorial link for same


WebFocus 8104,8204
Excel/PDF/HTML/HTMLTABLE/XML/ALPHA/GIF file/GRAPH/Active technologies
 
Posts: 182 | Location: INDIA | Registered: July 11, 2013Reply With QuoteReport This Post
Master
posted Hide Post
FOCdeveloper, yes, it is a .fex that I call using -INCLUDE.

The key is using Linux to return the Zulu date/time because that is what Report Caster uses. I'm not sure how you would do that in a Windows server environment, I never looked it up.

-* File rc_submit.fex
-*
-* This job tell Report Caster to submit the desired job for execution at the
-* current time plus 1 minute
-*
-* The only parameter is the Report Caster schedule id
-*
-* To use this in a fex, do the following
-* -SET &RCJOBID=scheduld_id;
-* -INCLUDE rc_submit
-*
-* To use this in Report Caster, add the following in the pre or post processing fex
-* baseapp/rc_submit RCJOBID=schedule_id
-*
-*-SET &RCJOBID=S52089096s861bs4dc2sa025s8c0779769b44;
-*
 APP PATH report_caster
-*
-* Get the Interval Id for the schedule
-*
 TABLEF FILE BOTSIT
  PRINT INTERVALID
  WHERE SCHEDULEID EQ '&RCJOBID'
     ON TABLE SAVE
 END
-RUN
-READ SAVE &LNGTH.6. &INTERVALID.64.
-RUN
-SET &INTERVALID=TRUNCATE(&INTERVALID);
-UNIX rm save.ftm
-*
-*  Get the next run date/time in zulu time plus 1 minute
-*
 APP FI ZULUTIME DISK zulutime.txt ( LRECL 32 RECFM V
-RUN
-UNIX date +%s > zulutime.txt
-RUN
-READ ZULUTIME &ZULUSEC.32.
-RUN
-*
 DEFINE FILE MACGYVER
   ZULUSEC/P32=&ZULUSEC;
   ZULUDAYS/I9=ZULUSEC/86400;
   ZULUHRS/I9=(ZULUSEC-(ZULUDAYS*86400))/3600;
   ZULUMIN/I9=(ZULUSEC-((ZULUDAYS*86400)+(ZULUHRS*3600)))/60;
   ZULUTIME/P32L=((ZULUDAYS*86400)+(ZULUHRS*3600)+((ZULUMIN+1)*60))*1000;
 END
-*
 TABLE FILE MACGYVER
 PRINT ZULUTIME
    IF COUNTER EQ 1
    ON TABLE SAVE
 END
-*
 DEFINE FILE MACGYVER CLEAR
 END
-RUN
-READ SAVE &NEXTRUNTIME.32.
-RUN
-UNIX rm save.ftm
-TYPE .
-TYPE .  Submitting:
-TYPE .    Schedule Id: &RCJOBID
-TYPE .    Interval Id: &INTERVALID
-TYPE .      Zulu Time: &NEXTRUNTIME
-TYPE .
-*
 MODIFY FILE BOTSIT
 FIXFORM INTERVALID/64
 MATCH INTERVALID
    ON MATCH COMPUTE NEXTRUNTIME='&NEXTRUNTIME.EVAL';
    ON MATCH UPDATE NEXTRUNTIME
    ON MATCH SQL COMMIT WORK
    ON MATCH/NOMATCH GOTO TOP
 DATA
&INTERVALID
 END
-RUN


In FOCUS since 1985. Prod WF 8.0.08 (z90/Suse Linux) DB (Oracle 11g), Self Serv, Report Caster, WebServer Intel/Linux.
 
Posts: 919 | Location: Oklahoma City | Registered: October 27, 2006Reply With QuoteReport This Post
Platinum Member
posted Hide Post
Thanks jgelona,

I will try the code and let you know if i need your help.

Thank you so much.

Regards,
Neelima


WebFocus 8104,8204
Excel/PDF/HTML/HTMLTABLE/XML/ALPHA/GIF file/GRAPH/Active technologies
 
Posts: 182 | Location: INDIA | Registered: July 11, 2013Reply With QuoteReport This Post
Platinum Member
posted Hide Post
Thanks Jgelona


WebFocus 8104,8204
Excel/PDF/HTML/HTMLTABLE/XML/ALPHA/GIF file/GRAPH/Active technologies
 
Posts: 182 | Location: INDIA | Registered: July 11, 2013Reply With QuoteReport This Post
  Powered by Social Strata  
 

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED]Run ReportCaster Job Dynamically

Copyright © 1996-2018 Information Builders, leaders in enterprise business intelligence.