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

Announcements
Write Table now available in Qlik Cloud Analytics: Read Blog
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

"Not in" expression for straight table

Hi,

Say I have two dimensions like below


Dim1:

A

B

C

D

E

Dim2:

A

B

C

D

In the above example, the value E is in Dim1 but it's not in Dim2. Is there some function or expression I can use to find all the values that are in one dimension but are not in another? So in this case it would just return E. The two dimensions come from different data sources, and one of them (Dim2) is in a data island if that makes any difference.

Thanks.

1 Solution

Accepted Solutions
maxgro
MVP
MVP

4 Replies
Clever_Anjos
Employee
Employee

Please check if fits your needs

=Concat({<Dim1-=P(Dim2)>} Dim1)

maxgro
MVP
MVP

PFA

sunny_talwar

May be something like this:

=Concat({<Dim1 = e({<Dim1 = p(Dim2)>})>}Dim1, ',') & ',' & Concat({<Dim2 = e({<Dim2 = p(Dim1)>})>}Dim2, ',')

I slightly changed the inputs:

Table:

LOAD * INLINE [

    Dim1

    A

    B

    C

    D

    E

];

Table1:

LOAD * INLINE [

    Dim2

    A

    B

    C

    D

    F

];

Text Object Output = E,F

HTH

Best,

S

Not applicable
Author

This one worked for me, thanks to everyone for the replies, really appreciate it.