Qlik Community

New to Qlik Sense

If you’re new to Qlik Sense, start with this Discussion Board and get up-to-speed quickly.

Announcements
Tell us which business and trade publications you read most regularly: RESPOND NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
LauraMorris
Contributor II
Contributor II

Use string stored in variable for wildmatch

Hi

I have a wildmatch funtion which is used in multiple places within my loadscript. There are a lot of ID's being matched against so I want to store them in a variable and call them into each wildmatch so that they can all be updated easily.

So far I have:

Let $vClient='180,191,213,219,228,255,320,322';

[client]:
LOAD
clientid,
clientname
FROM [lib://qvds/client.qvd](qvd)

WHERE match(clientid,'$(vClient)');

 

This is returning me 0 rows whilst if I put the contents of the string into the match I get 16 rows.

I have tried using " instead of ' in all combinations in the variable and in the match.

1 Reply
danilostochi
Creator II
Creator II

Hi,

try it.

 

 

SET vClient = 180, 191, 213, 219, 228, 255, 320, 322;

[client]:
LOAD
clientid,
clientname
FROM [lib://qvds/client.qvd](qvd)

WHERE match(clientid, $(vClient));

+55(44) 9 9993-3605, WhatsApp
E-Mail or Skype - danilo16stochi@hotmail.com