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.
I am very new to FOCUS and have very little experience with it. I need to do the following. Calculate an Expiry date which should equal to todays date + 1 day. If the Expiry date falls on a Saturday or Sunday then the Expiry date should be move to the following Monday. The expiry and Input date should be in the MDY format but I belive that for DOWK you have to use the YMD format Here is my code: COMPUTE INP_DATE/MDYY = '&MDYY'; EXP_DATEA/YYMD = '&YYMD' + 1; EXP_DATEX/MDYY = INP_DATE + 1; EXP_DATEY/MDYY = INP_DATE + 2; DAY/A4 = DOWK(EXP_DATEA,DAY); ADJ/A1 = DECODE DAY (MON '1' TUE '1' WED '1' THU '1' FRI '1' SAT '2' SUN '1'); EXP_DATE/MDYY = IF ADJ EQ '2' THEN EXP_DATEY ELSE EXP_DATEX;
The Input Date is the system date. The problem is no matter on what day the expiry date falls I am always getting the expiry date as the input date + 1.
I would really appreciate if someone could tell me what I was doing wrong.
Your DECODE doesn't have an ELSE, so you don't know if DAY is even being calculated right. I suspect it isn't. I don't think you can add integer dates the way you are doing it. &MDYY is an integer date, not a smart date.
Posts: 391 | Location: California | Registered: April 14, 2003
Vanessa- You may also want to take a look at the 'business days' capability of WebFOCUS. Also check out the 'holiday' feature. Also look at WD (Weekday) in DATEADD. You can search for these by using the 'Search the Technical Documentation Library' button in the upper right corner of this screen. HTH
Posts: 252 | Location: USA | Registered: April 15, 2003