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

Help in using not exists

Hi All,

I have two tables in the script.

Table A: It has a master list of all the IDs.

Table B: It has some IDs which may or may not be present in the master ID list of Table A.

I want to create a third table where only those IDs would be loaded which are not present in the master table.

Thanks,

Asma

4 Replies
avinashelite

Load * inline

[

ID, score

1,100

2,600

3,300

];

Table2:

[

ID2, score

3,100

4,600

5,300

];

Load *

resident Table2

where

not exist (ID2,ID);

Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

Table A: It has a master list of all the IDs.

So, Table A contains all the ID's

those MSIDs would be loaded which are not present in the master table

But you just said that Table A contains all the ID's. So there cannot be ID's that do not exist in the master table.


talk is cheap, supply exceeds demand
PrashantSangle

Hi,

Use Approch suggested by Avinash

just make sure Exists() contain 2 parameter

the 1 st is field which you want to search for

and 2 nd field is your searching field

just make some modification in Avinash script

TABLE1:
Load * inline
[

ID, score

1,100

2,600

3,300

];

Table2:
Load * inline
[

ID2, score

3,100

4,600

5,300

];

NoConcatenate

fINAL_tABLE:
Load *
resident Table2
where
not existS(ID,ID2);

Regards

Great dreamer's dreams never fulfilled, they are always transcended.
Please appreciate our Qlik community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved 🙂
engishfaque
Specialist III
Specialist III

Dear Asma,

Here is a logic,

Table_A:

LOAD IDs

FROM

(ooxml, embedded labels, table is Sheet1)

Where NOT Exists(IDs);

Right Join (Table_A)

LOAD IDs

FROM

(ooxml, embedded labels, table is Sheet1)

Where NOT Exists(IDs);

Kindly find attached document for clear understanding.

Kind regards,

Ishfaque Ahmed