Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
BrandonN
Contributor II
Contributor II

Set Analysis not working after covert to variable

Hi All,

After I convert the expression to load inline as variable the expression not work .

Anyone can advise?

vFinalOutput

Thanks!

1 Solution

Accepted Solutions
rubenmarin
MVP
MVP

Hi, the quick solution is to use replace to omit using characters like $ or ', to avoid to interpret them and just load the string, like:

LET vFinalOutput = Replace(Replace('Sum({<[DateMonth] = {|#(=#(vMaxYear))|}>}Record)','#','$'),'|',Chr(39));

So | will load as ' and # will load as $.

Another most common solution is using an external file to load variables with values assigned, loading from excel file also avoid the interpretation of $( or '.

https://community.qlik.com/t5/QlikView-App-Dev/Loading-variables-through-Excel-File/m-p/1263071

View solution in original post

2 Replies
rubenmarin
MVP
MVP

Hi, the quick solution is to use replace to omit using characters like $ or ', to avoid to interpret them and just load the string, like:

LET vFinalOutput = Replace(Replace('Sum({<[DateMonth] = {|#(=#(vMaxYear))|}>}Record)','#','$'),'|',Chr(39));

So | will load as ' and # will load as $.

Another most common solution is using an external file to load variables with values assigned, loading from excel file also avoid the interpretation of $( or '.

https://community.qlik.com/t5/QlikView-App-Dev/Loading-variables-through-Excel-File/m-p/1263071

BrandonN
Contributor II
Contributor II
Author

Thanks for sharing!