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] deference of function run between 7701 and 7703

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED] deference of function run between 7701 and 7703
 Login/Join
 
Member
posted
-SET &MONTH='201105';
-SET &FIRST_MONTH=&MONTH||'01';


-SET &DATE1=DATEADD(&FIRST_MONTH,'D',1);
-TYPE &DATE1
-SET &DATE2=DATEADD(&FIRST_MONTH,'M',1);
-TYPE &DATE2
-SET &DATE3=DATECVT(&DATE1,'YYMD','A8YYMD');
-TYPE &DATE3

7703:
20110502
569611005
69610906

7701:
20110502
20110601
20110601

who can tell me why?
thanks!

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


webfocus 7701 ,windows 7 64bit ,All Output
 
Posts: 7 | Registered: February 24, 2012Report This Post
Master
posted Hide Post
First DATEADD does directly work with Dialogue Manager. Neither does DATEMOV or DATEDIF. Do a search on UDATEADD. You will find a DEFINE FUNCTION that will work with Dialogue Manager. You can also create similar Functions for DATEMOV and DATEDIF.


In FOCUS since 1985. Prod WF 8.0.08 (z90/Suse Linux) DB (Oracle 11g), Self Serv, Report Caster, WebServer Intel/Linux.
 
Posts: 975 | Location: Oklahoma City | Registered: October 27, 2006Report This Post
Master
posted Hide Post
Per the 7702 Using Functions Manual:
quote:
Do not use DATEADD with Dialogue Manager. DATEADD requires a date to be in date format; Dialogue Manager interprets a date as alphanumeric or numeric.
Perhaps take a look at the following amendments to your code:
-SET &MONTH='201105';
-SET &FIRST_MONTH=&MONTH | '01';
-TYPE &FIRST_MONTH
-*
-SET &DATE1=AYMD(&FIRST_MONTH,1,'I8YYMD');
-TYPE &DATE1
-*
-SET &DATE2=AYM(&MONTH,1,'I6YYM');
-SET &DATE2 = &DATE2 | '01';
-TYPE &DATE2
-EXIT  

Yielding:
20110501
20110502
20110601




Pilot: WebFOCUS 8.2.06 Test: WebFOCUS 8.1.05M Prod: WebFOCUS 8.1.05M Server: Windows Server 2016/Tomcat Standalone Workstation: Windows 10/IE11+Edge Database: Oracle 12c, Netezza, & MS SQL Server 2019 Output: AHTML/XLSX/HTML/PDF/JSCHART Tools: WFDS, Repository Content, BI Portal Designer & ReportCaster
 
Posts: 822 | Registered: April 23, 2003Report This Post
Virtuoso
posted Hide Post
DATEADD and other SmartDate-only functions can be used in Dialogue Manager (DM), but the DM dates must first be converted to SmartDate integers with function DATECVT. Note that the DM dates must be identified as numeric and not alpha in DATECVT (I8YYMD, not A8YYMD). After performing the desired SmartDate math (DATEADD in this case), the SmartDate integers must be converted back to DM dates. But as David indicates, the legacy date functions AYMD and AYM will handle DM dates directly and do not require conversion to/from SmartDate formats.

-SET &MONTH = '201105';
-SET &FIRST_MONTH = &MONTH || '01';
-*
-SET &DATE1 = DATECVT(DATEADD(DATECVT(&FIRST_MONTH,'I8YYMD','YYMD'),'D',1),'YYMD','I8YYMD');
-SET &DATE2 = DATECVT(DATEADD(DATECVT(&FIRST_MONTH,'I8YYMD','YYMD'),'M',1),'YYMD','I8YYMD');
-*
-TYPE &DATE1
-TYPE &DATE2


WebFOCUS 7.7.05
 
Posts: 1213 | Location: Seattle, Washington - USA | Registered: October 22, 2007Report This Post
Member
posted Hide Post
thanks all


webfocus 7701 ,windows 7 64bit ,All Output
 
Posts: 7 | Registered: February 24, 2012Report 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] deference of function run between 7701 and 7703

Copyright © 1996-2020 Information Builders