Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi.
This is my sql query in qlikview script.
Select
code,
type
From
table
Where
type in (1,2,5)
Now I don't want type to contain (1,2,5).
I want it to come from a variable.
how do i define the variable, and how do I change the query where expression.
Thank You.
Like this:
SET vList = 1,2,5;
Select
code,
type
From
table
Where
type in ($(vList));
Try like below:
LET vTypes = '(1,2,5)' ;
TYPE:
SQL SELECT CODE,
TYPE
FROM TABLE_NAME
WHERE TYPE IN $(vTypes) ;