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.
Some of our users do not want to receive an email from the Report Caster if the report is empty. We currently handle this by checking &LINES in the report. If &LINES is zero, we jump to -EXIT.
However, to stop the Report Caster sending us an 'Empty Report' error notification, we have to change the job to ‘Never’ send out a notification. This is not ideal as the report may crash due to a genuine error and we won't find out!
Therefore is there another way, to not send a report if empty and to also be told if the report has a problem?
CheersThis message has been edited. Last edited by: Kerry,
WebFocus 765. iSeries v5r4
Posts: 175 | Location: England | Registered: April 11, 2006
Here's a couple of things. You should NOT schedule jobs in RC that have a -EXIT. This causes problems with RC when encountered because the process stops prematurely not allowing RC to finish what it needs to do.
There is a parameter called &&KILL_RPC that you can include to cancel further RC processing.
-SET &&KILL_RPC = IF &LINES EQ 0 THEN 'Y' ELSE 'N';
If at any time the value of the parameter is set to 'Y' then RC immediately stops. no emails, no reports. A log record is written out and that's it. However, you may also want to test &FOCERRNUM to make sure that the problem was truly zero records and not a report crash.
Regards,
Darin
In FOCUS since 1991 WF Server: 7.7.04 on Linux and Z/OS, ReportCaster, Self-Service, MRE, Java, Flex Data: DB2/UDB, Adabas, SQL Server Output: HTML,PDF,EXL2K/07, PS, AHTML, Flex WF Client: 77 on Linux w/Tomcat
Posts: 2298 | Location: Salt Lake City, Utah | Registered: February 02, 2007
If bursting gives records for some but not all users, that means that &LINES does have a non-zero value. The bursting is done AFTER the report finishes, based on the results. So processing will continue as usual. Only if there is no data at all to be distributed Darin's approach will kick in.
GamP
- Using AS 8.2.01 on Windows 10 - IE11.
in Focus since 1988
Posts: 1961 | Location: Netherlands | Registered: September 25, 2007
it does not test per burst value - only for the total report. IBI has been messing around in the latest version to allow for some different notifications based on whether or not a specific burst value contains data rather than sending an error message. This was always an annoyance to me because in many of my jobs, all burst values don't always have a report (in fact, they almost never do) so I almost always get an error report, when there really was no error except "there was no data for burst value xx " I can't remember what the latest functionality was but they didn't change it in previous versions and I'm not on the latest. Might be able to find it by searching techsupport case notes or the forum.
Regards,
Darin
In FOCUS since 1991 WF Server: 7.7.04 on Linux and Z/OS, ReportCaster, Self-Service, MRE, Java, Flex Data: DB2/UDB, Adabas, SQL Server Output: HTML,PDF,EXL2K/07, PS, AHTML, Flex WF Client: 77 on Linux w/Tomcat
Posts: 2298 | Location: Salt Lake City, Utah | Registered: February 02, 2007
I have a scheduled job that has several tasks perform on the same dataset. I don't mind sending one empty report to the users but not all. Is there a way to do it?
Hua
Developer Studio 7.6.11 AS400 - V5R4 HTML,PDF,XLS
Posts: 305 | Location: Winnipeg,MB | Registered: May 12, 2008
Not exactly sure what you mean, but you can probably use the same method described above. After each task, test &LINES and add 1 to a &&counter if it's empty. After the last task is performed, test the &&counter to see if ALL reports were empty then set &&KILL_RPC='Y'. If each task in the job is executed on its own thread (agent), you might have to -WRITE and -READ to a file to get this to work as the &&var may not be perpetuated through completion of all the tasks.
Regards,
Darin
In FOCUS since 1991 WF Server: 7.7.04 on Linux and Z/OS, ReportCaster, Self-Service, MRE, Java, Flex Data: DB2/UDB, Adabas, SQL Server Output: HTML,PDF,EXL2K/07, PS, AHTML, Flex WF Client: 77 on Linux w/Tomcat
Posts: 2298 | Location: Salt Lake City, Utah | Registered: February 02, 2007
Sorry, I should've give you more detail the first time. Say I have 4 separate tasks/threads/agents/fexes(how ever you call them) scheduled in the same job. One fex produces the summary and rest are various detail reports. I like to stop the job once the summary is empty and email ONE empty report to the users.
Developer Studio 7.6.11 AS400 - V5R4 HTML,PDF,XLS
Posts: 305 | Location: Winnipeg,MB | Registered: May 12, 2008
Thanks, what you suggests sounds perfect....however I can't get it to work?!
Test fex:
TABLE FILE CAR PRINT * WHERE COUNTRY EQ '&COUNTRY'; ON TABLE HOLD AS TEST END -RUN
-SET &&KILL_RPC = IF &LINES EQ 0 THEN 'Y' ELSE 'N';
TABLE FILE TEST PRINT * END -RUN
I run a Report Caster where &COUNTRY is set to 'ITALY' and I get a report containing 5 lines.
I then change this to 'XXX' and I still get an email error notification stating empty report, which is what I am trying to avoid (Report Caster set to only report on error):
quote:
BTP1010 Starting worker thread BTP1020 Starting task: Task 1 BTP1020 Task type: EDA RPC BTP1020 Procedure name: dev/car BTP1020 Connecting to server EDASERVE with execution id iadmindev BTP1020 Executing focexec. BTP1020 No report to create. BTP1020 WARNING. YOU REQUESTED PRINT * OR COUNT * FOR A MULTIPATH FILE BTP1020 Task finished. BTP1010 No report to distribute.
Any thoughts?
WebFocus 765. iSeries v5r4
Posts: 175 | Location: England | Registered: April 11, 2006
By using the &&KILL_RPC you are in fact forcing an error. So RC sends you the error report. What we do is use outlook to filter this kind of error reports and delete it without reading. (the system reads the line "no report to distribute")
Frank
prod: WF 7.6.10 platform Windows, databases: msSQL2000, msSQL2005, RMS, Oracle, Sybase,IE7 test: WF 7.6.10 on the same platform and databases,IE7
Posts: 2387 | Location: Amsterdam, the Netherlands | Registered: December 03, 2006
By using the &&KILL_RPC you are in fact forcing an error. So RC sends you the error report. What we do is use outlook to filter this kind of error reports and delete it without reading. (the system reads the line "no report to distribute")
Hi Frank,
Yep I guess that is one way of dealing with it, however from reading Darin's post it sounds like we should be able to avoid the email being sent out at all?
If this isn't the case I think we will have to go with the Outlook method, however I think this could be a nice thing for the IBI guys to look at and perhaps add to a future release?
Cheers
WebFocus 765. iSeries v5r4
Posts: 175 | Location: England | Registered: April 11, 2006
Sorry - I seem to have created a little bit of confusion. The determination to set the &&KILL_RPC flag must be executed as a pre-processing procedure (with an ON TABLE HOLD). This determines whether or not the scheduled task(s) should run. Once the schedule tasks begin to execute, they will all run until completed. The use of this flag is documented in the RC Administration Manual (mine are 7.1.3 and it's in appendix C) I don't know where it is in other versions. Pre-processing procedures are also discussed in the same manual. Sorry if there was a mis-direction there. My suggestion would be to run your first report (using a parameter to determine whether it is pre processing or not to branch around the HOLD), and set &&KILL_RPC is no records are found. Might be a little overhead, so you'll have to determine if the solution causes another problem.
Regards,
Darin
In FOCUS since 1991 WF Server: 7.7.04 on Linux and Z/OS, ReportCaster, Self-Service, MRE, Java, Flex Data: DB2/UDB, Adabas, SQL Server Output: HTML,PDF,EXL2K/07, PS, AHTML, Flex WF Client: 77 on Linux w/Tomcat
Posts: 2298 | Location: Salt Lake City, Utah | Registered: February 02, 2007
Yes, it is possible to suppress the error messages, but then you will never get an error message also not if there is an other reason the process did not work.
It's a matter of settings in this special RC process. (some check settings)
Frank
prod: WF 7.6.10 platform Windows, databases: msSQL2000, msSQL2005, RMS, Oracle, Sybase,IE7 test: WF 7.6.10 on the same platform and databases,IE7
Posts: 2387 | Location: Amsterdam, the Netherlands | Registered: December 03, 2006
What about : SET EMPTYREPORT = ON. Or, -IF &RECORDS EQ 0 THEN GOTO NoDataToShow ; Where NoDataToShow contains a -HTMLFORM BEGIN / END or a DEFINE / TABLE FILE request which produces a No Data To Show message?
Just some good thoughts that worked for my at previous locations... -Doug
Posts: 3132 | Location: Tennessee, Nashville area | Registered: February 23, 2005
How to not distribute Report Caster if report is empty
your suggestion creates a report that informs the receivers of the report that there is no data. Nice to know, but if you just do not want a report if there is no data ???
It's like receiving an empty envelop!!!
Frank
prod: WF 7.6.10 platform Windows, databases: msSQL2000, msSQL2005, RMS, Oracle, Sybase,IE7 test: WF 7.6.10 on the same platform and databases,IE7
Posts: 2387 | Location: Amsterdam, the Netherlands | Registered: December 03, 2006
Good point... Oh, the question... And a alternative solution...
Actually, the client will get what they request. However, what about 'Positive Reporting'? Would the recipient, who did not get their report, think that they did not get it because there was no report to deliver or was it due to a system error and they did not get their report which could be critical. Perhaps Mark66 should go back to the client and present this scenario.
IMHO... - DougThis message has been edited. Last edited by: Doug,
Posts: 3132 | Location: Tennessee, Nashville area | Registered: February 23, 2005
In Release 7.6.4 a new setting was added to the ReportCaster Configuration Tool labeled 'Default Processing for No Report to Distribute'. This value of this setting is 'Error' by default. This means that a No Report to Distribute condition is an error and triggers error notification. If you change this setting to Warning then a No Report to Distribute condition is considered a warning and does not trigger error notification. This is a global setting whose value affects all schedules.
WebFOCUS All Releases
Posts: 45 | Location: NYC | Registered: September 21, 2007
Gerry's suggestions worked for me for few days. Now I'm getting emails and Log file shows in red color "Unable to retrieve data for the distribution list". I didn't change any settings in WebFocus & ReportCaster. Any ideas why it stopped working?
WF 7.6.4, Win XP, SQL 2005
Posts: 42 | Location: California | Registered: August 17, 2007
My distribution list comes as a result of WebFocus procedure. This procedure retrieves data from SQL 2005 and it is scheduled to run every 1 minute. If there are records returned by procedure then it will send report by email (another procedure called to generate report) to users. If there are no records returned by procedure then there is no email to users and I don't want to get email notifications about error (no data should not be considered as error). However, I do see message "Unable to retrieve data for the distribution list" in the ReportCaster Log file and I receive emails about error every 1 minute despite I selected "Warning" in "Default Processing for No Report to Distribute" setting. The simplified procedure for distribution list below:
ENGINE SQLMSS SET VARCHAR OFF
SET SQLENGINE=SQLMSS
ENGINE SQLMSS SET DEFAULT_CONNECTION 811DEV
SQL SQLMSS PREPARE SQLOUT FOR
SELECT DISTINCT APAN8, EAEMAL FROM F085520W, F01151 WHERE APAN8=EAAN8 AND EAAN8 IN
(SELECT DISTINCT APAN8 FROM F085520W WHERE APESIGN<>'' AND
DATEDIFF(MI, CRPDTA.sJulianToNormalDate(APUPMJ) + ' ' +
CRPDTA.formatMilitaryToStandardTime(APUPMT), GETDATE()) < 2)
END
DEFINE FILE SQLOUT
APAN8/I8 = APAN8;
END
TABLE FILE SQLOUT
PRINT
APAN8
EAEMAL
ON TABLE HOLD AS HFILE
END
-RUN
-* Procedure for bursting (see page 3-23 in ReportCaster manual).
SET ASNAMES=ON
TABLE FILE HFILE
PRINT APAN8 AS 'VALUE'
EAEMAL AS 'DEST';
ON TABLE PCHOLD
END
WF 7.6.4, Win XP, SQL 2005
Posts: 42 | Location: California | Registered: August 17, 2007
Yes, this procedure creates only email adress list. Another procedure creates reports which are sent to those email addresses. I had no problems with this code in WF 7.1.6 and it works in 7.6.4, except errors sent to me when no records returned by procedure (only in 7.6.4). It is necessary to do this (run procedure which creates email address list) every minute according to functional requirements.
WF 7.6.4, Win XP, SQL 2005
Posts: 42 | Location: California | Registered: August 17, 2007
Originally posted by Seva: Gerry's suggestions worked for me for few days. Now I'm getting emails and Log file shows in red color "Unable to retrieve data for the distribution list". I didn't change any settings in WebFocus & ReportCaster. Any ideas why it stopped working?
Seva,
In your case it hasn't stopped working. You are getting messages because "Unable to retrieve data for the distribution list" is an error not a warning. Without the distribution list the report can not be distributed.
This is a very different scenario than "No Report to distribute". Check your edaprint.log for any errors on the fex that produces the distribution list.
Cheers
Stu
WebFOCUS 8.2.03 (8.2.06 in testing)
Posts: 253 | Location: Melbourne, Australia | Registered: February 07, 2007
I suspected that message "Unable to retrieve data for the distribution list" may be different from message "No Report to distribute". In my case it is not clear what is the difference between these messages because procedure open_enroll_address.fex runs every 1 minute and usually there is no report to distribute every 1 minute. Which is fine, but why do I get errors "Unable to retrieve data for the distribution list" in Log file and by email? However, if the records exist (when employee submits Open Enrollment info, record with time stamp is inserted into database) then reports are distributed fine. The interesting thing is that after I changed setting for "Default Processing for No Report to Distribute" from "Error" to "Warning", I did not see errors "Unable to retrieve data for the distribution list" in Log file and I did not receive emails with these errors for few days. After few days I'm getting the same errors in Log file and emails. I did not touch any WebFocus or ReportCaster settings during these few days.
WF 7.6.4, Win XP, SQL 2005
Posts: 42 | Location: California | Registered: August 17, 2007