Qlik Community

Ask a Question

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
QlikView forum consolidation is complete. Labels are now required. LEARN ABOUT LABELS
cancel
Showing results for 
Search instead for 
Did you mean: 
patricesalem
Creator
Creator

Wild Card in set Expression with variable

Hello

I'm trying to combine the use of wild cards and variable in set expression for producing a chart & table (qlik sense sheet)

Here is what works  (use of " front of PROMOUP):

sum({<Year={'$(=$(vCurrentYear))'},[Hierarchie-hierarchie]-={'PIECE'},[cde_achat]={"*PROMOUP*"}>}qte_commandee)

If I replace PROMOUP by a variable (vPromo), the following works :

sum({<Year={'$(=$(vCurrentYear))'},[Hierarchie-hierarchie]-={'PIECE'},[cde_achat]={$(vPromo)}>}qte_commandee)

I don't manage to get it to work with vPromo and *

Any idea about the correct syntax ?

thanks

1 Solution

Accepted Solutions
patricesalem
Creator
Creator

Bingo !

sum({<[cde_achat]= {"*$(=(vPromo))*"}>}net_commande),

only remove the $ front of the variable parenthesis

thanks for your support

View solution in original post

4 Replies
sunny_talwar

How is vPromo defined?

patricesalem
Creator
Creator

in the variable module

for test purpose, I have set it up as follow:

Image 1855.jpg

then the user will be able to change it using qsvariable :

Image 1856.jpg

patricesalem
Creator
Creator

I have just noticed that the following expression works

sum({<[cde_achat]={"*$(=$(vPromo))*"}>}net_commande)

only if the inputbox field is between quotes '  '

Image 1857.jpg

but I don't want the user to write ' '

patricesalem
Creator
Creator

Bingo !

sum({<[cde_achat]= {"*$(=(vPromo))*"}>}net_commande),

only remove the $ front of the variable parenthesis

thanks for your support

View solution in original post