Skip to main content
Announcements
SYSTEM MAINTENANCE: Thurs., Sept. 19, 1 AM ET, Platform will be unavailable for approx. 60 minutes.
cancel
Showing results for 
Search instead for 
Did you mean: 
ndenicola
Partner - Contributor II
Partner - Contributor II

Where Clause with Wildcard

Hello Everyone,

In my data set, there is a column called SUPPORTTEAM that displays all the support teams for the company, however I am trying to create a where clause that limits the SUPPORTTEAM to only Member Services and Service Executives. This would mean limiting the data to any field in the SUPPORTTEAM column that begins with MemberServices_ or SC_.

I created a WHERE clause at the bottom of my script (listed below) but Qlik Sense is giving me a "Line error" message.

WHERE [SUPPORTTEAM] = ('MemeberServices*' OR 'SC*');

Any suggestions?

1 Solution

Accepted Solutions
sunny_talwar

May be this:

Where WildMatch(SUPPORTTEAM, 'MemberServices*'', 'SC*');


Where WildMatch(SUPPORTTEAM, 'MemberServices*', 'SC*');

I think there was a typo in MemberServices.

View solution in original post

7 Replies
sunny_talwar

May be this:

Where WildMatch(SUPPORTTEAM, 'MemberServices*'', 'SC*');


Where WildMatch(SUPPORTTEAM, 'MemberServices*', 'SC*');

I think there was a typo in MemberServices.

ndenicola
Partner - Contributor II
Partner - Contributor II
Author

It was the typo. The WILDMATCH didn't work, but the original clause with the fixed field name did. Thank you!

sunny_talwar

Very strange,I would not have thought this expression to be correct

WHERE [SUPPORTTEAM] = ('MemeberServices*' OR 'SC*');

Not applicable

You can either use LIKE or WILDMATCH function. But as you stated, WILDMATCH is not working. May be you can try with WildMatch with mix match cases.

WildMatch(SUPPORTTEAM,'*member*s*vices','SC*)

sunny_talwar

dathu.qv‌ I can understand why WildMatch did not work, but do you know how the other syntax is working?

Where [SUPPORTTEAM] = ('MemeberServices*' OR 'SC*');


Saravanan_Desingh

You can also try like this..

Where [SUPPORTTEAM] = If([SUPPORTTEAM] Like 'MemeberServices*'

                                             OR

                                             [SUPPORTTEAM] Like 'SC*',

                                             [SUPPORTTEAM])

;

Not applicable

Sunny, as per knowledge, the Initial syntax won't work and TS(thread starter) mentioned very first beginning.

I may suspect , TS tweak the values on the field and come with specific working pattern on the WildMatch.