Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All
i have two tables like below
yesterday:
record id
1
2
3
4
today:
record id
1
2
3
4
5
6
expected output :
record id ,tag
1, old record
2, old record
3, old record
4,old record
5,new record
6,new record
can u please help me with this
thanks in advance
regards
siva
Hello Siva,
Basically, that's a question for 'Incremental load' in qlikview.
Which can be easily achieved with the Exists() function.
Example script you can plug and play:
OldSource:
LOAD * Inline [
ID
1
2
3
4
];
JOIN (OldSource)
LOAD
'old record' as tag
AutoGenerate (1)
;
NewSource:
NoConcatenate
LOAD * Inline [
ID
1
2
3
4
5
6
]
WHERE NOT Exists(ID)
;
JOIN (NewSource)
LOAD
'new record' as tag
AutoGenerate (1)
;
Concatenate(OldSource)
LOAD
ID,tag
Resident NewSource;
DROP TABLE NewSource;
Hello Siva,
Basically, that's a question for 'Incremental load' in qlikview.
Which can be easily achieved with the Exists() function.
Example script you can plug and play:
OldSource:
LOAD * Inline [
ID
1
2
3
4
];
JOIN (OldSource)
LOAD
'old record' as tag
AutoGenerate (1)
;
NewSource:
NoConcatenate
LOAD * Inline [
ID
1
2
3
4
5
6
]
WHERE NOT Exists(ID)
;
JOIN (NewSource)
LOAD
'new record' as tag
AutoGenerate (1)
;
Concatenate(OldSource)
LOAD
ID,tag
Resident NewSource;
DROP TABLE NewSource;