I know there are lot of postings on this subject. But can't seem to find the solution. I have a report to run that require to filter out all the weekends (Saturday & Sunday) for the month. Do I create a holiday file for the weekends or use SET BUSDAYS?
Regards,
TanThis message has been edited. Last edited by: <Kathryn Henning>,
R7.7.0.1 Windows, All Outputs
March 25, 2015, 04:09 AM
atturhari
I would create a DEFINE to convert the database dates into a day format then apply a filter on DEFINE field where it is not equal to SAT or SUN
March 25, 2015, 04:10 AM
Tony A
Hi Tan,
If you need this as a filter, then neither.
If this was a FOCUS data source, then I would be inclined to use DOWK function to obtain the day of week and then filter WHERE NOT field IN ('Sat','Sun') etc.
A word of warning, this type of define is unlikely to be translated to SQL at all so, if your source is SQL then maybe look at re-defining the existing date column as USAGE=W, ACTUAL=DATE instead of HDMYYs etc. in your synonym - although I doubt that this will translate well either
Always check the SQL trace to ensure that your extraction process is as efficient as possible.
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
March 26, 2015, 05:07 AM
JS
Dear Atturhari & Tony,
Thank you for your advise. I will make the changes at database level.