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.
This file has been placed on our reporting server in this directory: C$\ibi\srv81\wfs\bin\
Here is my test procedure:
-SET &ECHO=ALL; SET HDAY = TEST; DEFINE FILE CAR A/YYMD = '20170101'; B/YYMD = '20170107'; END TABLE FILE CAR PRINT A B COMPUTE DELTA_BD/I3 = DATEDIF(A, B, 'BD'); BY HIGHEST 1 COUNTRY END -RUN
When I run this I get a value of 5 instead of 4 for DELTA_BD. In the source code I found this error:
(FOC209) THE DATA VALUE EXCEEDS ITS LENGTH SPECIFICATION: TEST;
This is the second HDAY file I've tried. The first had the name of the holiday a space after the date. Trying to avoid bugging our sys admins with changes so if anyone sees an error with what I'm doing I would greatly appreciate it.
Best,
Barron FuentesThis message has been edited. Last edited by: Tamra,
Also, it seems you can have the holiday date file in a reporting server application folder (that's part of the path), so you won't need to bother the sys admin. You may be able to access the baseapp app folder without the need of the sys admin.
From the doc:
quote:
By default, the holiday file has a file name of the form HDAYxxxx.err and is on your path
Francis
Give me code, or give me retirement. In FOCUS since 1991
Production: WF 7.7.05M, Dev Studio, BID, MRE, WebSphere, DB2 / Test: WF 8.1.05M, App Studio, BI Portal, Report Caster, jQuery, HighCharts, Apache Tomcat, MS SQL Server
SET HDAY = TEST DEFINE FILE CAR A/YYMD = '20170101'; B/YYMD = '20170107'; END TABLE FILE CAR PRINT A B COMPUTE DELTA_BD/I3 = DATEDIF(A, B, 'BD'); BY HIGHEST 1 COUNTRY END -RUN
Returns this error: (FOC1892) FILE NOT FOUND : HDAYTESTERRORS *
I do have access to the baseapp application folder and have dropped the HDAYTEST.ERR file in the directory. However, I still receive the file not found error.
Barron. You should have a FILEDEF for your holiday file. Be sure that the holiday file encompasses the dates you use. Also set the BUSDAY parameter:
FILEDEF HDAYTEST DISK C:\ibi\srv81\wfs\HDAYTEST.ERR
SET BUSDAY=SMTWT__
SET HDAY = TEST
DEFINE FILE CAR
A/YYMD = '20170129';
B/YYMD = '20170205';
END
TABLE FILE CAR
PRINT A B
COMPUTE DELTA_BD/I3 = DATEDIF(A, B, 'BD');
BY HIGHEST 1 COUNTRY
END
-RUN
HDAYTEST.ERR
20170101 New Year
20170131 Last day of January
20171231 Sylvester
Daniel In Focus since 1982 wf 8.202M/Win10/IIS/SSA - WrapApp Front End for WF
Posts: 1980 | Location: Tel Aviv, Israel | Registered: March 23, 2006
FILEDEF HDAYTEST DISK C:\ibi\srv81\wfs\HDAYTEST.ERR
SET BUSDAY=_MTWTF_
SET HDAY = TEST
DEFINE FILE CAR
A/YYMD = '20170129';
B/YYMD = '20170205';
END
TABLE FILE CAR
PRINT A B
COMPUTE DELTA_BD/I3 = DATEDIF(A, B, 'BD');
BY HIGHEST 1 COUNTRY
END
-RUN
I get a file not found error: (FOC1892) FILE NOT FOUND : HDAYTESTERRORS *
Same result with a path of C:\ibi\srv81\wfs\bin\HDAYTEST.ERR. I also added a copy of HDAYTEST.ERR to C:\apps\baseapp\ and used FILEDEF to point it but also received a file not found error.
Francis, I seem to recall that if the HDAYxxxx.err file was to be found in the path, FILEDEF wasn't necessary. But this was quite some time ago...
Barron, Are you sure you put the file on the server? Maybe it is on your machine where you have a copy of DS or AS but you are running against the WebFOCUS server which is on another machine?
Daniel In Focus since 1982 wf 8.202M/Win10/IIS/SSA - WrapApp Front End for WF
Posts: 1980 | Location: Tel Aviv, Israel | Registered: March 23, 2006
Thanks for your help on this. I couldn't get it working from the C:\ibi\srv81\wfs folder (file not found error still).
I was able to get it working using FILEDEF and corrected an error in my baseapp folder path.
Here's the working code:
FILEDEF HDAYTEST DISK C:\ibi\apps\baseapp\HDAYTEST.ERR SET BUSDAY=_MTWTF_ SET HDAY = TEST DEFINE FILE CAR A/YYMD = '20170101'; B/YYMD = '20170107'; END TABLE FILE CAR PRINT A B COMPUTE DELTA_BD/I3 = DATEDIF(A, B, 'BD'); BY HIGHEST 1 COUNTRY END -RUNThis message has been edited. Last edited by: Barron,