Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Identify type of joining

Colleagues, good day!

Simple question:

Script loads first table:

 

IdField1
1A
2A
3A
4A
5A
6A

Then i must load second table but only data for those Id which are not contain in first table:

Second:

 

IdField2
1B
2B
3B
4B
8B
9B

In result i must get only:

 

IdField2
8B
9B

Thanks.

14 Replies
Anonymous
Not applicable
Author

Try on your second load :

     where not exists (Id)

sunny_talwar

May be like this:

A:

LOAD Id,

           Field1

FROM....

B:

LOAD Id,

           Field2

FROM ...

Where not Exists(Id);

DROP Table A;

Anonymous
Not applicable
Author

Thanks!

It works.

But how QV Know, what previous table must be checked for already exist values? (Id in this case)

johnca
Specialist
Specialist

Maybe like this?

temp1:

Load * Inline [

  Id, Field1

  1,A

  2,A

  3,A

  4,A

  5,A

  6,A

  ];

TEMP2:

NoConcatenate

Load *

Where Not Exists (Id);

Load * Inline [

  Id, Field1

  1,B

  2,B

  3,B

  4,B

  8,B

  9,B

  ];

Drop Table temp1;

Anonymous
Not applicable
Author

QlikView checks the data model for the field Id and looks up values already loaded into the field.  This is done at the field level, not the table level.

sunny_talwar

This is how Exist function works where it checks against all possible value within a field previously loaded in the script.

marcus_sommer

Qlik checked for this the values within the symbol-tables, see here what is meant: Symbol Tables and Bit-Stuffed Pointers.

- Marcus

Anonymous
Not applicable
Author

Thanks))

And is is possible to check for some fields combinations?

For ex:

First table:

 

IdF1
1A
2A
3A
4A
5B
6

B

Second:

 

IdF1
13
2ed
3fd
4dfd
5fdf
6B
7u

for where not Exists(Id&F1) i must get only:

 

IdF1
5fdf
7u

but it returns empty result

Anonymous
Not applicable
Author

Thanks!