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.
First time poster here. I've done a lot of searching on the forums but can't solve my problem. I want to have the DEFAULT value for a date paramater to be today's date.
In dialogue manager, I tried many attempts but nothing works
I would assume something like this: -DEFAULT &DATETO = &YYMD;
would return an actual date, but it doesn't.
Can anyone give me some tips?
Thanks, JoshThis message has been edited. Last edited by: <Kathryn Henning>,
WebFOCUS 8004 Windows Server 2008 R2 Standard 64-bit All Outputs
Well, obviously because it would override any value that was entered through the parameter.
You can work around that with approaches like below, but frankly it's kind of annoying that -DEFAULT doesn't evaluate expressions.
-DEFAULT &DATETO = FOC_NONE;
-SET &DATETO = IF &DATETO EQ FOC_NONE THEN &YYMD ELSE &DATETO;
WebFOCUS 8.1.03, Windows 7-64/2008-64, IBM DB2/400, Oracle 11g & RDB, MS SQL-Server 2005, SAP, PostgreSQL 11, Output: HTML, PDF, Excel 2010 : Member of User Group Benelux :
Isn't the reason for that to work because the amper-variable contains the value &YYMD.EVAL though, and not the actual value of &YYMD (today: 20131202)?
With that in place, the amper-variable expression would get evaluated wherever the amper-variable gets used and it would appear to have set the default to the desired expression result.
I'm sure there are some cases where that distinction would actually matter, but I can't think of any right now, which makes it kind of hard to create a test-case to prove this one way or the other... Takers?
WebFOCUS 8.1.03, Windows 7-64/2008-64, IBM DB2/400, Oracle 11g & RDB, MS SQL-Server 2005, SAP, PostgreSQL 11, Output: HTML, PDF, Excel 2010 : Member of User Group Benelux :
It is an interesting conundrum as to what the DEFAULT of &DATETO will contain with a &YYMD.EVAL.
Realistically, DEFAULT does not evaluate, it only holds what the value entered is. This is correct, as Wep5622 understands.
If you remove the .EVAL, then &DATETO will be &YYMD when seen.
So theoretically &DATETO contains &YYMD.EVAL, and when seen, with a -TYPE or any other DM function, will be the evaluated value. A bit like Hiesenberg's uncertainty principle. It is impossible to actually prove either way.
Alan. WF 7.705/8.007
Posts: 1451 | Location: Portugal | Registered: February 07, 2007
I think the only way to prove this one way or another is to turn tracing on and check to see what actually happens.
I think what you will find is that if the .EVAL is part of the code and not the contents of the variable, it will be evaluated, if its part of the variable it will not.
Perhaps what happens could be made more obvious by comparing the performance of the assignment of a static value to whatever happens when this using .EVAL.
So, the dynamic DEFAULT took 8.781s, while the static DEFAULT took 8.958s. Those values are close enough together that it doesn't look like that .EVAL gets evaluated each time in the loop. That would mean that the .EVAL is indeed evaluated when the DEFAULT value gets assigned.
However, it is possible that DM is smart enough to see that it can cache the value after the first eval in the loop, in which case the above doesn't mean much...
WebFOCUS 8.1.03, Windows 7-64/2008-64, IBM DB2/400, Oracle 11g & RDB, MS SQL-Server 2005, SAP, PostgreSQL 11, Output: HTML, PDF, Excel 2010 : Member of User Group Benelux :
Interpretation of a fex file proceeds serially (except as modified by -GOTO or -REPEAT).
when parsing
-DEFAULT &DYNAMIC=&YYMD.EVAL;
the .EVAL interrupts the process; "&YYMD.EVAL" is replaced by the character-string value stored in &YYMD (e.g., "20131203"), and then parsing of the resulting line
-DEFAULT &DYNAMIC=20131203;
resumes where it was interrupted (after the equal sign); when the end of the line is reached, the -DEFAULT is executed, setting &DYNAMIC to '20131203' (if its value had not previously been -SET).
That all happens after the prior lines are scanned and executed, and before any subsequent lines are considered.
Posts: 1925 | Location: NYC | In FOCUS since 1983 | Registered: January 11, 2005