Focal Point
[CASE CLOSED] multiselect field using a hold file (variable) data

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/3157041186

March 07, 2016, 11:32 AM
vnf
[CASE CLOSED] multiselect field using a hold file (variable) data
Hello,


I am trying to get have a multi select field from a variable entry from user.

I will try to replicate this using the CAR file for this purpose.

The first part: I will get the value from user: In this case country is the variable field and then I will save MODEL in a HOLD file VALID_CODES

2nd part, I would like to allow the user to multi-select/choose from the already filtered Model list In my purpose, In my own project I will be using another file instead of the same CAR file but for this purpose I will use CAR file again.

my issue is that I can not get the 2nd step to work in my code. Does someone knows how to address this ?


APP PREPENDPATH IBISAMP
SET ASNAMES = ON
SET HOLDLIST = EXPLICIT

TABLE FILE CAR
PRINT
CAR.CARREC.MODEL
WHERE COUNTRY EQ &COUNTRY.(OR(FIND COUNTRY IN CAR)).Country.;
ON TABLE NOTOTAL
ON TABLE HOLD AS VALID_CODES FORMAT ALPHA
END


TABLE FILE CAR
SUM SALES BY COUNTRY BY CAR BY MODEL
-*WHERE COUNTRY IN FILE VALID_CODES
WHERE MODEL EQ &MODEL.(OR(FIND MODEL IN VALID_CODES)).Sold To:.; ---> this line does not work in my code

END

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


WebFOCUS 8.2.0.7,
Application Studio,
Webfocus Info-Assist
iWay Service Manager,
iWay Data Migrator
Windows, All Outputs
IBM DB2/400, MS SQL-Server 2014
March 09, 2016, 09:10 AM
dhagen
You have to put VALID_CODES in a re-usable directory. I suggest using FOCCACHE. When you do a hold, the file gets put in the temp-disk, and that will be cleaned up when the process ends. FOCCACHE is unique to the user, and it persists multiple report calls in the same session.

TABLE FILE CAR
PRINT
CAR.CARREC.MODEL
WHERE COUNTRY EQ &COUNTRY.(OR(FIND COUNTRY IN CAR)).Country.;
ON TABLE NOTOTAL
ON TABLE HOLD AS foccache/VALID_CODES FORMAT ALPHA
END  



"There is no limit to what you can achieve ... if you don’t care who gets the credit." Roger Abbott
March 09, 2016, 03:50 PM
vnf
thank you


WebFOCUS 8.2.0.7,
Application Studio,
Webfocus Info-Assist
iWay Service Manager,
iWay Data Migrator
Windows, All Outputs
IBM DB2/400, MS SQL-Server 2014