Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Good morning,
I'm dealing with the following problem. I have a field containing variables names (VariableName) associated 1to1 to another one (here VariableNumber):
I have created three variables:
And I'd like to be able to expand the variables in correspondence to the VariableNumber used as a dimension in a table. Precisely, I'd like the output:
I tried many syntax, like these:
but nothing seems to work, and I wonder if it's actually doable.
Thanks in advance!
Variable resolution is done before expression evaluation, so you cannot resolve to a different variable name row by row. What you can do is reference all the potential variables and use if() logic to select the correct value for each row. For example, like this:
Pick(Match(VariableName, 'var1', 'var2', 'var3'), '$(var1)', '$(var2)', '$(var3)')
-Rob
http://www.easyqlik.com
http://masterssummit.com
http://qlikviewcookbook.com
In regard what you are showing you could simply add the vVariableLongName as another field within the inline-load or keeping the information within an associated table. But I assume that's not the goal behind your question ...
I am assuming you are trying to show the contents for the variable?
Have you tried $("only(VaraibleName)")
Variable resolution is done before expression evaluation, so you cannot resolve to a different variable name row by row. What you can do is reference all the potential variables and use if() logic to select the correct value for each row. For example, like this:
Pick(Match(VariableName, 'var1', 'var2', 'var3'), '$(var1)', '$(var2)', '$(var3)')
-Rob
http://www.easyqlik.com
http://masterssummit.com
http://qlikviewcookbook.com