Qlik Community

Qlik Sense App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

Announcements
BARC’s The BI Survey 19 makes it official. BI users love Qlik. GET REPORT
abc_18
Contributor

Issue with if conditional with wildmatch expression

Hello everyone,

In front end, I have used conditional wildmatch expression to show / hide the columns, but it's taking too much time to load a table chart. plesae suggest how can I improve the performance or modify the expression. In business field I have three different values.

Business

ABC

XYZ

XXX

 

Column 1:- Expression is :-

if(wildmatch(getfieldselections(Business),'ABC'), 1, 0)

or

if(wildmatch(getfieldselections(Business),'XYZ'), 1, 0)

 

So if I select business=ABC or XYZ then only a column 1 will be visible, but if I select XXX as business this column should be hidden.

Labels (2)
2 Replies
Partner
Partner

Re: Issue with if conditional with wildmatch expression

you could try
if(wildmatch(getfieldselections(Business),'ABC','XYZ')>0, 1, 0)
also if you are looking at exact matches use match function instead of wildmatch as the performance is better.
But more on performance. If you remove the condition is it better?
MVP & Luminary
MVP & Luminary

Re: Issue with if conditional with wildmatch expression

I assume that you have rather a general performance issue with your object and/or the datamodel as an issue with the condition of your expression. Nevertheless you could try to change it to:

wildmatch(getfieldselections(Business),'*ABC*', '*XYZ*')

- Marcus