Focal Point Banner
Community Center Education Summit Technical Support User Groups
Let's Get Social!

Facebook Twitter LinkedIn YouTube
Go
New
Search
Notify
Tools
Reply
  
-SET before -RUN
 Login/Join
 
Gold member
posted
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
-*
 
Posts: 64 | Location: Denver | Registered: July 20, 2005Reply With QuoteReport This Post
Expert
posted Hide Post
Can 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.
   Most recent: 8204 Gen 48 in Test and Production.
   Currently Available. Please contact me.
 
Posts: 3040 | Location: Middle Tennessee [8204M Gen48 in Test&Prod] | Registered: February 23, 2005Reply With QuoteReport This Post
Expert
posted Hide Post
Joan,

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.06 on Windows Svr 2008 R2  
WebFOCUS App Studio 8.2.06 standalone on Windows 10 
 
Posts: 5617 | Location: United Kingdom | Registered: April 08, 2004Reply With QuoteReport This Post
Gold member
posted Hide Post
Thanks Tony and Doug.

I was afraid the answer would be like this.
Sigh.
Back to the drawing board.
 
Posts: 64 | Location: Denver | Registered: July 20, 2005Reply With QuoteReport This Post
Virtuoso
posted Hide Post
This 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 Big Grin


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
 
Posts: 2298 | Location: Salt Lake City, Utah | Registered: February 02, 2007Reply With QuoteReport This Post
Expert
posted Hide Post
I agree with you, Darin! Good One


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
 
Posts: 2723 | Location: Ann Arbor, MI | Registered: April 05, 2006Reply With QuoteReport This Post
Gold member
posted Hide Post
Well, 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.
 
Posts: 64 | Location: Denver | Registered: July 20, 2005Reply With QuoteReport This Post
Virtuoso
posted Hide Post
Give 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
 
Posts: 2298 | Location: Salt Lake City, Utah | Registered: February 02, 2007Reply With QuoteReport This Post
  Powered by Social Strata  
 


Copyright © 1996-2018 Information Builders, leaders in enterprise business intelligence.