Focal Point
[CLOSED] Adding filter in master files for current year / month / quarter

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/5567007276

September 17, 2014, 11:29 AM
Param
[CLOSED] Adding filter in master files for current year / month / quarter
Hi,
I am new to Web Focus. How can I set up a filter in master file to get current year , current Month and Current quarter.

Thanks

This message has been edited. Last edited by: <Kathryn Henning>,
September 18, 2014, 05:15 AM
Tony A
Firstly, you do not state which version or platform that you are using. Please add this to your signature (follow the link under forum guidelines above).

Assuming that you're on a recent version, ensure you understand the use of filters within a synonym (master file). link to documentation search for master file filter.

You will need to have some global variables setup in a server profile or similar.

A suggestion for the global variables is -
-SET &&CURMONTH = DPART(DATECVT(&YYMD, 'I8YYMD', YYMD), 'MM', 'I11');
-SET &&CURQTR   = DPART(DATECVT(&YYMD, 'I8YYMD', YYMD), 'QQ', 'I11');
-SET &&CURYEAR  = DPART(DATECVT(&YYMD, 'I8YYMD', YYMD), 'YEAR', 'I11');


Next you will need to get these global variables available to use in your synonym, so you will need to add them in via the GUI - in Dev Studio the icon looks like a blue speech bubble with a white V.

Good luck

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