Discussion Board for collaboration on QlikView Scripting.
i want to store value of load statement in a variable. is it possible?
i have a excel file with values below:
i want to store in a variable like below:
let rate= load rate from excelfile where item='coe';
and rate variable should give value as 0.23
please advise with right steps
Go to Solution.
WHERE item = 'coe'
LET vRate = PEEK('rate',-1,'tmpTable')
DROP TABLE tmpTable;
use peek function
EX: let rate=peek( 'FieldName', 0, 'TableName' )
let rate = peek(load rate from excelfile where item='coe');
you can assign lookup function value as your variable value. Take a look into definition of lookup function in Reference Manual.
First read in peek function in help. See the below syntex.(Single quotes must)
FieldName = Finding field name
TableName= Finding table name
Please correct me .
You wanted to maintain Data in Excel and from that you need to fetch particular row with the some conidition and then you want to assign it to Varaible .
What i can suggest is that you can maitain the Variable directly in the Excel sheet .
So if you want to change value you can cahnge in the Excel itself instead of changing the value in thescript .