Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
curiousfellow
Specialist
Specialist

Store formulas/expressions in variables

To make expressions not to complicated, I stored some expressions in variables. The stored expressions contain variables too.

Should it be possible to use variables like this. For every dimension I get the same result now.

For example : stored in var1 = sum({<year={"=$(var_chosen_year)"}>}sales)

                                                var2 = sum({<year={"=$(var_compare_year)"}>}sales)

In my chart :

dimension : department

expression: $(var1)-$var(2)

 

 

Labels (1)
1 Solution

Accepted Solutions
curiousfellow
Specialist
Specialist
Author

SOLVED : I created the content of the variable starting with the "=" sign". Without that character it works 

View solution in original post

2 Replies
curiousfellow
Specialist
Specialist
Author

SOLVED : I created the content of the variable starting with the "=" sign". Without that character it works 

MayilVahanan

Hi

For Dynamic, remove the "=" equal sign from the formula and try like $(var1)

var1:

sum({<year={"=$(var_chosen_year)"}>}sales)

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.