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     [SOLVED] holiday file

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED] holiday file
 Login/Join
 
Platinum Member
posted
Hello,
I am trying to make a holiday file for a daydiff function. Looking through the posts here in focal point, I have gotten as far as making my file and putting it in:
ibi\srv76\wfs\bin\HDAYDOFF.ERR

The contents of that file are as follows:
20090101
20090119
20090410
20090525
20090703
20090907
20091126
20091221
20091222
20091223
20091224
20091225

However, when I run this code:
SET HDAY = DOFF
SET BUSDAYS = SMTWTFS
-RUN

TABLE FILE CAR
PRINT
COUNTRY
COMPUTE DAT1/YYMD = 20091201 ;
COMPUTE DAT2/YYMD = 20091231 ;
COMPUTE DTDIFF/I2 = DATEDIF(DAT1, DAT2, 'BD');
END

The output is 30 days difference. It should be 25 since the 21st through the 25th of December is in my holiday file.

Now, when I run this code, just to test to see if WF even recognizes the file:
SET HDAY = DOFF
-RUN

I get this message:
(FOC1892) FILE NOT FOUND : HDAYDOFFERRORS *

Can anyone help me figure out how I can get a holiday file to work? Thank you!

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


Windows version 768
 
Posts: 215 | Registered: March 16, 2006Report This Post
Expert
posted Hide Post
quote:
SET HDAY = DOFF
SET BUSDAYS = SMTWTFS
-RUN


The location and name of your file looks correct, the SET command looks correct - you MAY need a -RUN right after the SET HDAY command for it to be applied before the SET BUSDAYS command.

The following commands lets you know if the SET HDAY command worked:

SET HDAY = DOFF
-RUN

-? SET HDAY &VARHDAY
-RUN

-TYPE &VARHDAY

-? SET HDAY &VARHDAY puts the value of the HDAY setting in a variable called &VARHDAY. If the result of the -TYPE command is blank, then the SET HDAY command did not work.


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
 
Posts: 10577 | Location: Toronto, Ontario, Canada | Registered: April 27, 2005Report This Post
Virtuoso
posted Hide Post
Mark,

I ran your exact code on my environment (which today is windows xp based) and there it runs without any problem, and gives me the correct number of days (25). My release level is 767.

It may be that the older release has problems with the file being uppercase.
Try to change the name to all lowercase and see if that helps.


GamP

- Using AS 8.2.01 on Windows 10 - IE11.
in Focus since 1988
 
Posts: 1961 | Location: Netherlands | Registered: September 25, 2007Report This Post
Platinum Member
posted Hide Post
Thank you for your help. However, I still cannot get WF to recognize the file. When I ran your code, Francis, I got the same error message:
(FOC1892) FILE NOT FOUND : HDAYDOFFERRORS *

Changing to lowercase did not work either. BTW - I have 767 on Windows XP professional. I have not updated my profile, yet.

Is a .err file different from a regular .txt file? I made my holday file using a new text document and saved it with an extension of .err.
Did I do something wrong there?

TomP - can you expand a little bit on what you mean when you say "Search for HOLIDAY FILE".


Windows version 768
 
Posts: 215 | Registered: March 16, 2006Report This Post
Platinum Member
posted Hide Post
One more thing I found out... when I do a search in Windows Explorer for filenames with .err, all of the .err files have a type of "ERR File" except for the one I created has a file type of "Text Document", even though the extension is .err. How can I fix this? Thanks!

Also, all of the other .err files are in srv76\home\nls


Windows version 768
 
Posts: 215 | Registered: March 16, 2006Report This Post
Expert
posted Hide Post
Mark1, the err file is just a text file with an err suffix.

Are you sure the contents of the file are correct?

Are you sure the directory you placed the file in is the same one as being read by the WF server?

It appears the suffix can be lower or upper case, but the file name must be uppercase, and be 8 characters long beginning with 'HDAY'.


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
 
Posts: 10577 | Location: Toronto, Ontario, Canada | Registered: April 27, 2005Report This Post
Expert
posted Hide Post
Correction:

The filename must be five to eight characters long beginning with 'HDAY' in uppercase.


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
 
Posts: 10577 | Location: Toronto, Ontario, Canada | Registered: April 27, 2005Report This Post
Platinum Member
posted Hide Post
I think I fixed it. What I did was that I went into the file location where all of the other .err files were. I copied one and edited it with notepad erasing what was in there and putting in my dates. Then I ran Francis' code again and the result was:
DOFF

Then I ran my original code and got a 25 day difference!!! Yeah!!!!

BTW - the file location that worked for me was:
ibi\srv76\home\nls

Thanks for all of your help!


Windows version 768
 
Posts: 215 | Registered: March 16, 2006Report This Post
Expert
posted Hide Post
This may seems like a stupid question, but are you doing this on the localhost srv76/wfs/bin subdirectory or did you put the file on the 'real' WebFOCUS reporting server bin directory?


Ginny
---------------------------------
Prod: WF 7.7.01 Dev: WF 7.6.9-11
Admin, MRE,self-service; adapters: Teradata, DB2, Oracle, SQL Server, Essbase, ESRI, FlexEnable, Google
 
Posts: 2723 | Location: Ann Arbor, MI | Registered: April 05, 2006Report This Post
Expert
posted Hide Post
quote:
Are you sure the directory you placed the file in is the same one as being read by the WF server?


This could very well be the reason...


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
 
Posts: 10577 | Location: Toronto, Ontario, Canada | Registered: April 27, 2005Report This Post
Virtuoso
posted Hide Post
According to the manual the holiday file should be placed on the WebFocus server in directory: \ibi\srv76\wfs\bin


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, 2006Report This Post
Expert
posted Hide Post
quote:
all of the .err files have a type of "ERR File" except for the one I created has a file type of "Text Document"
To me, this is the give away statement and I would lay money on the fact that you've file extensions hidden for known file types?

When you saved your file from within your text editor and gave it the filename hdaydoff.err (what you thought was an extension), i would guess that it actually saved the file hdaydoff.err.txt. When you have looked at it in explorer allyou've seen is hdaydoff.err.

WebFOCUS wouldn't have used a file of that name because the extension was wrong, the .err is treated as part of the filename.

T



In FOCUS
since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2  
WebFOCUS App Studio 8.2.06 standalone on Windows 10 
 
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004Report This Post
Platinum Member
posted Hide Post
You are probably right, Tony. I have done that before by accident. So, what is the easiest way to create a .err file then? You open a new text document... then what?


Windows version 768
 
Posts: 215 | Registered: March 16, 2006Report This Post
Expert
posted Hide Post
From windows explorer, I usually right click and create new text file and change the name and extension as required. Then I open it with my favorite editor. Each to their own method, but it works for me.

T
 
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004Report This Post
Expert
posted Hide Post
I gave up with the hidden file extensions long ago, otherwise, you don't realy know what it is or could be.


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.07OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!

 
Posts: 6347 | Location: 33°49'23.0"S, 151°11'41.0"E | Registered: October 31, 2006Report This Post
Virtuoso
posted Hide Post
Just to update, 7.7 appears to need a FILEDEF for this problem.

 
FILEDEF HDAYDOFF DISK C:\ibi\srv77\wfs-Reporting-Production\bin\HDAYDOFF.ERR
SET HDAY = DOFF
-RUN



 
Posts: 1012 | Location: At the Mast | Registered: May 17, 2007Report 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     [SOLVED] holiday file

Copyright © 1996-2020 Information Builders