Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Conditionnal dimension (text not like)

Hi everyone, I've got a problem. It must be easy, but I still haven't figured it out how to solve it.

If in my chart, I put a condion on one of my dimension like "=fonc_nom_budget like '*Principal*'", I have the result that I want.

If I want to have the opposite result, like "=not(fonc_nom_budget like '*Principal*')" , it doesn't.

It doesn't pick out the name with "Principal" in. I've got all the possible results.

I've tried with =fonc_nom_budget<>'Principal' , same thing. I'm sure that it's easy, but I can't find it.

Thanks for the help !

4 Replies
MK_QSL
MVP
MVP

=IF(fonc_nom_budget<>'Principal' , fonc_nom_budget)

alexandros17
Partner - Champion III
Partner - Champion III

Do not use like, use wildmatch(fonc_nom_budget , 'Principal')'

In this way you can test

wildmatch(fonc_nom_budget , 'Principal')' = -1 (True)

wildmatch(fonc_nom_budget , 'Principal')' = 0 (False)

Hope it helps

er_mohit
Master II
Master II

USE WILDMATCH FUNCTION     like

if(wildmatch(fonc_nom_budget ,'*Principal*'),fonc_nom_budget )

for not match try this

if(fonc_nom_budget <>wildmatch(fonc_nom_budget ,'*Principal*'),fonc_nom_budget )

Not applicable
Author

Thanks all, I used a mix of your answers : =if(wildmatch(fonc_nom_budget ,'*PRINCIPAL*')=0,fonc_nom_budget )