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

Mixing InputFiles

Hi,

In the example below I try to mix different input files.
From new files only new lines may be selected. When I use “
WHERE NOT EXISTS (KEY)” nothing of file
B will be selected. In my opinion the second line of file B should be selected.
That’s what I want.

  //=====EXAMPLE=========================================================================
:
LOAD * INLINE [
DATE, TICKET, LINE, SHOPCODE, QTY, KEY
05-06-2013, 100, 1, SH1, 10, SH1_100_1
05-06-20...



















;

CONCATENATE LOAD
     
DATE,
    
TICKET,
    
LINE,
    
SHOPCODE,
    
QTY,
     
KEY
RESIDENT
WHERE NOT EXISTS (KEY);

DROP TABLE ;
DROP TABLE ;

12 Replies
lironbaram
Partner - Master III
Partner - Master III

your mistake is

as you have table B then all keys are exists in the model already so nothing is reloaded

you can do it like this

[SALES]:
NOCONCATENATE LOAD
     
DATE,
    
TICKET,
    
LINE,
    
SHOPCODE,
    
QTY,
     
KEY AS NewKEY

CONCATENATE LOAD
     
DATE,
    
TICKET,
    
LINE,
    
SHOPCODE,
    
QTY,
     
KEY AS NewKEY
RESIDENT
WHERE NOT EXISTS (NewKEY,KEY);

DROP TABLE ;
DROP TABLE ;

qlikpahadi07
Specialist
Specialist

your Query is not clear bit confusing. what Out put exactly want ?

Not applicable
Author

Thanks guys for your great help. Many answers where correct. It is clear to me now so I can finish my script.