Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

Showing results for 
Search instead for 
Did you mean: 
Creator II
Creator II

Incremental load issue

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;


Set vLoadType = 'Incremental';
Set vDate = Num(Today());

End If

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?

Labels (1)