Qlik Community

Ask a Question

App Development

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

Announcements
April 22, 2PM EST: Learn about GeoOperations in Qlik Sense SaaS READ MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
roccoxpecora
Contributor III
Contributor III

Using Wildcard when creating a bucket

Hello Qlik users.

I'm creating buckets in a preceding load but with text values not numerical.

So currently it looks like:

     Load*,

       if([ImplementationProjectType]='Credit-Brand Flip','Credit',

               if([ImplementationProjectType]='Credit-Conversion','Credit',

                          if([ImplementationProjectType]='Debit-Existing','Debit','Other'))) as Imp_Type;

Is there a way to use wildcard(*) instead of writing each out value. I tried a couple ways and couldn't get it to work. If someone could help with the syntax to be able to utilize '*Credit*' somehow instead of writing that would great.

Thanks so much

1 Solution

Accepted Solutions
swuehl
MVP
MVP

Try the WildMatch() function:

  Load*,

       if(WildMatch( [ImplementationProjectType], '*Credit*'),'Credit',

                          if([ImplementationProjectType]='Debit-Existing','Debit','Other')) as Imp_Type;

View solution in original post

2 Replies
swuehl
MVP
MVP

Try the WildMatch() function:

  Load*,

       if(WildMatch( [ImplementationProjectType], '*Credit*'),'Credit',

                          if([ImplementationProjectType]='Debit-Existing','Debit','Other')) as Imp_Type;

View solution in original post

sunny_talwar

In addition to doing it Stefan's way, you can also do it this way:

LOAD *,

          If(ImplementationProjectType LIKE '*Credit*', 'Credit',

          If(ImplementationProjectType = 'Debit-Existing', 'Debit', 'Other'));

LOAD ....