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

Announcements
Qlik Connect 2026! Turn data into bold moves, April 13 -15: Learn More!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

if statement?

hi

i hope anyone of you can help me

i have two tables:

productmanagers:

productmanager,

productmanagerName

articles:

article.name,

article.group,

article.productmanager   as productmanager                   

                                                 

productmanager is a short expression for the whole name with two letters, for example: productmanagername: max mustermann - productmanager: mm. (article.productmanager is also the short expression)

there are hundreds of productmanagerNames and only a few 'article.productmanagers'

now i want the listbox to show the productmanagersNames* but only these who are 'article.productmangers'. is this possible?

thanks

6 Replies
avinashelite

Hi dominik,

Try this:

if(len(article.productmangers)>0,productmanagers)

or

if your trying to get the productmanagers who are also article.productmangers then:

if(article.productmangers=productmanagers,productmanagers)

ashfaq_haseeb
Champion III
Champion III

Try below

 

articles:

article.name,

article.group,

article.productmanager   

from articles.qvd

productmanagers:

productmanager,  

productmanagerName

from productmanagers.qvd where exsists(article.productmanager,productmanager)

Regards

ASHFAQ

its_anandrjs
Champion III
Champion III

Try with

productmanagers:

LOAD

productmanager,

productmanagerName 

From Location;

Right Join(productmanagers)

articles:

LOAD

article.name,article.group,article.productmanager as productmanager

From Location;

Not applicable
Author

sorry, i meant that i'm trying to get the productmanagerNames who are also article.productmanagers

its_anandrjs
Champion III
Champion III

Hi,

From which fields this tables are associated i assume productmanager field then

productmanagers:

Load

productmanager,

productmanagerName

From Location;

Inner Join(productmanagers)

articles:

Load

article.name,

article.group,

article.productmanager as productmanager       

From Location;

Or without the join

productmanagers:

Load

productmanager,

productmanagerName

From Location;

articles:

Load

article.name,

article.group,

article.productmanager as productmanager        //Rename this field as productmanager       

From Location;

And in the front end try with

If( Len(productmanager)>1 , productmanagerName) //In any List box object write this expression

Not applicable
Author

thank you for your help, but it doesn't seem to work.

i'll show you my script so that you can see it better (i just simplified it before)

---------

user:

load upper(sachbearbeiter) as user

        user.sachbearbeitername as username

from user.qvd

-----------

------------

articles:

load article

         article.name

          article.group

          if (article.productmanager = ' ' , '[undefined]' , upper(article.productmanager)) as productmanager

from articles.qvd

------------

-----------

productmanagers:

load   user as productmanager

          username as productmanagername

resident user;

concatenate

load * inline

" productmanager, productmanagername

     [undefined], '[undefined]' ";

------------------

thank you very much!! :-))