Skip to main content
ArturoMuñoz
Employee
Employee

One of my favorite new things in Qlik Sense is the Set Expression section available in the Expression editor.  

The Set expressions section let users add complex set analysis to the expressions without typing it, which seems to me like a fantastic addition for new Qlik Sense users. Users decide whether they want to insert the current selection or a bookmark as a set expression. If available, users can choose which alternate state to base the current selection or the bookmark on.  

 The “Set expressions” section is available in the Expression editorThe “Set expressions” section is available in the Expression editor

How it works? 

Let us assume I have a chart that contains Sales by State and I want to add a simple condition to my expression where Year=2019. With Set expressions section a user could just select 2019 in the field Year as she would normally do and then pick “Use current selections” from the Expression editor. This will add the correct syntax into the expression. Something like:  

 

 

 

Sum({<Year={'2019'}>}[Actual Amount]) 

 

 

 

But if we add a bit of Qlik magic to it, then it gets more interesting, for example let say we want the Sales by State chart to show only the data for those Sales Reps that achieved their quota. (I’m using Consumer Sales app for this example) 

In the Sales Rep filter panel I can search those Sales Reps by using =sum([Sales Amount])>sum([Budget Amount]) in the search box. That will return the sales representatives that match that condition.  

 Screen Shot 2019-05-31 at 11.56.08 AM.png

 

 With this new feature adding a powerful set analysis to my expression gets easy, just by editing the chart expression for Sales and inserting the current selections I can achieve the example’s goal.

 

Screen Shot 2019-05-31 at 12.02.24 PM.png

 

Remember, you can also pick bookmarks and specify an alternate state if your app uses it. 

 

I hope you find it interesting. 

Arturo @arturoqv

2 Comments