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.
It use an internal matrix to reduce (or add) the number of days in a month to go to the previous or the next one without creating an invalid date.
Per example:
DEFINE FILE CAR
MTH1/YYMD=DATEADD('2014/03/31', 'M', -1);
MTH2/YYMD=DATEADD('2014/03/31', 'M', -2);
MTH3/YYMD=DATEADD('2014/03/31', 'M', -3);
MTH4/YYMD=DATEADD('2014/03/25', 'M', -5);
END
TABLE FILE CAR
BY COUNTRY NOPRINT
BY MTH1
BY MTH2
BY MTH3
BY MTH4
WHERE COUNTRY EQ 'FRANCE';
END
-RUN
Was just to show the result of month shift with different input date values. Was easier, I've been lazy But true, the input of DATEADD, must be a smartdate.
DEFINE FILE CAR
DTE/YYMD=&YYMD;
DT_1 /YYMD=DATEADD(DTE, 'M', -1);
END
TABLE FILE CAR
PRINT DTE DT_1
BY COUNTRY
WHERE COUNTRY EQ 'FRANCE';
END
WF versions : Prod 8.2.04M gen 33, Dev 8.2.04M gen 33, OS : Windows, DB : MSSQL, Outputs : HTML, Excel, PDF In Focus since 2007
Posts: 2409 | Location: Montreal Area, Qc, CA | Registered: September 25, 2013
seems to be a theme today. Tom, look up the AYMD and AYM functions, for working with &var dates, adding and subtracting. You'll enjoy knowing about them.
In Focus since 1979///7706m/5 ;wintel 2008/64;OAM security; Oracle db, ///MRE/BID
Posts: 3811 | Location: Manhattan | Registered: October 28, 2003