Focal Point
-SET before -RUN
September 18, 2008, 06:50 PM
Joan Williamson-Kelly-SET before -RUN
I want to use -SET for prompting from a file (table) that contains date values, but before that, I want to update the date values that are in that file (table) by dropping and re-creating it using HOLD FORMAT FOCUS.
Unfortunately, WebFOCUS seems to try to do the -SET before the -RUN commands.
Is there any way around this?
Code:
-* Data_Monthly_Run
APP HOLD STD_COST
!if exist "E:\IBI\APPS\data\month_list_lines.foc" (DEL "E:\IBI\APPS\data\month_list_lines.foc" /Q)
-RUN
TABLE FILE MONTH_LISTS
PRINT MONTH_LIST_KEY
BY HIGHEST MONTH_LIST_LABEL
ON TABLE HOLD AS MONTH_LIST_LINES FORMAT FOCUS
END
-RUN
*
-SET &&THIS_SEL = &MONTH_LIST1.(FIND 'HIGHEST MONTH_LIST_LABEL' IN month_list_lines).Current_Period.;
-SET &&LAST_SEL = &MONTH_LIST2.(FIND 'HIGHEST MONTH_LIST_LABEL' IN month_list_lines).Previous_Period.;
-INCLUDE Run_Data_By_Month
-*
September 18, 2008, 08:55 PM
DougCan you reproduce this using the CAR file? Or some other standard IB file?
On what are you running this (Environment)?
| In FOCUS Since 1983 ~ from FOCUS to WebFOCUS. Current: WebFOCUS Administrator at FIS Worldpay | 8204, 8206 |
September 19, 2008, 02:25 AM
Tony AJoan,
The syntax that you are using is for AutoPrompting when in the fex is preparsed to identify any undeclared variables and this process will identify &MONTH_LIST1 and MONTH_LIST2 as not having values and will build a launch page to prompt for these variable. This is action before any of the WF code is parsed so therefore your temporary hold file will not be available for populating your combo boxes in the autoprompt screen.
To achieve this you will need to ensure that your file is built before have e.g. it must exist before autoprompting screens are built. Try building it in overnight batch or have a synonym that will allow you to target just the data items that you will require.
Within your fex, it would appear that you wish to have a different display value to that passed by the HTML page as data. You cannot do this (I think) with amper autoprompting, so your options to do this will be limited.
Alternatively build your own launch page that will get your required data via a fex so that you can have different display values to data values.
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 | |
September 19, 2008, 02:44 PM
Joan Williamson-KellyThanks Tony and Doug.
I was afraid the answer would be like this.
Sigh.
Back to the drawing board.
September 22, 2008, 11:49 AM
Darin LeeThis is not a personal dig on Joan so no offense is intended. I think that the AUTOPROMPT functionality in WF is WAY overused. It don't think it was ever intended to be used in any way other than to quickly populate undeclared variables for easy execution of a report. My rule of thumb is that if this report is for an end-user/group (meaning anyone other than the author or another advanced user) AUTOPROMPT functionality should not be used.
It's very easy to create an HTML launch page, even if you only use the PUBLISH feature and then minor modifications. It seems that many, many users are going to extreme lengths to make it so things will appear properly and function in some predetermined way once autopromting kicks in. With an HTML page, it always works the way you intended, always prompts for the parameters as you intended, and you have control over the process flow as you intended.
I'll get of my soapbox now. Thanks for listening
Regards,
Darin
In FOCUS since 1991
WF Server: 7.7.04 on Linux and Z/OS, ReportCaster, Self-Service, MRE, Java, Flex
Data: DB2/UDB, Adabas, SQL Server Output: HTML,PDF,EXL2K/07, PS, AHTML, Flex
WF Client: 77 on Linux w/Tomcat
September 22, 2008, 11:53 AM
GinnyJakesI agree with you, Darin!
Ginny
---------------------------------
Prod: WF 7.7.01 Dev: WF 7.6.9-11
Admin, MRE,self-service; adapters: Teradata, DB2, Oracle, SQL Server, Essbase, ESRI, FlexEnable, Google
September 22, 2008, 06:03 PM
Joan Williamson-KellyWell, it's just frustrating. I guess without seeing what I'm doing, you won't know the whole story. I'm even having problems messing with the HTML. When I get time again, maybe I'll get it working.
It seems like in WF nothing works without trying several different avenues. I don't really have time for it.
September 22, 2008, 07:11 PM
Darin LeeGive Dennis or Peter a call in the Denver Branch office - they're pretty sharp with this stuff and will get you past your frustrations and hopefully a lot further.
Regards,
Darin
In FOCUS since 1991
WF Server: 7.7.04 on Linux and Z/OS, ReportCaster, Self-Service, MRE, Java, Flex
Data: DB2/UDB, Adabas, SQL Server Output: HTML,PDF,EXL2K/07, PS, AHTML, Flex
WF Client: 77 on Linux w/Tomcat