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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
sifatnabil
Specialist
Specialist

Re-use set analysis by replacing with a variable

Hi all,

If I have a long set analysis that I need to repeat in many places, can I store it in a variable and use it in other expressions? It doesn't seem to work if I try this:

In script:

set setanalysis={<ABC..>};

In expression:

count($(setanalysis) Id)

This causes an error.

1 Solution

Accepted Solutions
stabben23
Partner - Master
Partner - Master

Try to enclose Your variable With '{<ABC..}'

or create the Expression inside the GUI in variable overview (Ctrl+Alt+V)

View solution in original post

3 Replies
stabben23
Partner - Master
Partner - Master

Try to enclose Your variable With '{<ABC..}'

or create the Expression inside the GUI in variable overview (Ctrl+Alt+V)

stabben23
Partner - Master
Partner - Master

sifatnabil
Specialist
Specialist
Author

Thanks, the issue was that you can't put set analysis in script, as it cannot understand it -on the GUI, the variable has the phrase "Internal error" on it after reloading. Recreating the variable on the GUI fixed this.