Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
.Hi
I have table where there is no Last updated date and Sequential ID and i want to perform incremental load .
How can i do that?
Please share the complete scenario and Sample data
Hi Paramane,
In order to implement Incremental load there should be some unique identifier to identify the new entries, it can be date fields or serial id or even primary keys.
You can look in to the logic of hash keys as well.
http://www.qlikfix.com/2014/03/11/hash-functions-collisions/
Br,
KC
Hi,
If we don't have a ID and timestamp field, we need to generate in our script.
Temp:
LOAD Field1,
Field2,
Field3,
Field4,
Field5,
Field6,
AUTONUMBER(RowNo() & '-' & Field1 & '_' & Field2 & '_' & Field3 & '_' & Field4 & '_' & Field5 & '_' & Field6) as %Key_TaskFact //ID for incremental load
FROM
[sample.xlsx]
(ooxml, embedded labels, table is sample);
Temp1:
Load *,
//'03/01/2018' as Start, //For Mastercalendar
'28/12/2017' as Start, //For Mastercalendar
Date(Today(),'DD/MM/YYYY') as End //For Master Calendar
//Date('28/12/2025','DD/MM/YYYY') as End //For Master Calendar
Resident Temp;
Drop Table Temp;
Fact:
LOAD *,
Date(Start+IterNo()-1,'DD/MM/YYYY') as Date
Resident SR_Temp1 while Start+IterNo()-1 <= End;
Drop Table Temp1;
Store Fact into SR_Fact.qvd;
Drop Table SR_Fact;
Hello Varaha,
What is the table "SR_Temp1" ? because you don't have this table before..
Sorry for my english, I'm french.
Océane