Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi everyone.
I have an issue with incremental load. The script that I used to perform this load looks like this.
If IsNull('History.qvd') then
Set vLoadType = 'Full';
Set vDate = 0;
Else
Set vLoadType = 'Incremental';
Set vDate = Num(Today());
End If
LoadTable:
Load *,
Num(Date) as Period_FK
From Source.qvd(qvd)
Where Num(SourceDate) >= $(vDate);
Switch '$(vLoadType)'
Case 'Full'
Store LoadTable into LoadTable.qvd;
Drop Table LoadTable;
Case 'Incremental'
Concatenate (LoadTable)
Load *
From Source.qvd (qvd)
Where not Exists(Period_FK);
Store LoadTable into LoadTable.qvd;
Drop Table LoadTable;
End Switch
Everything OK with "Full" load. I got all periods with relevant amount of rows.Like this
But in case of Incremental load I suppose to see all previous data with new row for today date. Like this
But instead I got only today date an 1 row for each previous periods. Like this.
Why is it happened? How tho get relevant data in case of incremental load?