Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Dear Qlikview masters!
I am struggling on a case related to expressions evaluation.
My dataset is as following "Partners", "Forecast_Period" [0 to n], "Certified Value" and a toggle button to show or not the forecast [1 to n]
on my toggle button I did set the following action v_toggle_forecast=if(v_toggle_forecast=0,1,0)
a reusable filter as following : set v_Filter_Forecast = if(v_toggle_forecast,0,'*');
and a sum expression : set e_Liquidity_test = sum({<[Forecast_Period]={$(v_Filter_Forecast)}>} [Certified Value]);
if I put that expression in a graph diretly it works 🙂
if i have it in the script and call it in the graph using $(e_Liquidity_test) is doesn't 😞
In what order these expressions get expanded and evaludated?
Where is my mistake?
Thanks for your help!
Guillaume
The dollar sign expansion is changing your e_Liquidity_test definition to:
sum({<[Forecast_Period]={if(v_toggle_forecast,0,'*')}>} [Certified Value])
which is not a valid set modifier.
Have a look at the solutions shown here (I recommend the Excel table solution a the end):
Can I SET or LET a variable to include a $(=...)
And also have a look at
and double check the definitions of your variables with respect to leading equal signs.
That thread about magic of variables helped me initially to orientate my research.
But I think the trick of getting the dollar sign separated from the parenthesis will be the solution.
I let you know.