Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
gayatri7
Creator II
Creator II

Incremental Load from Excel File

Hi All,

I am trying to do incremental load from excel. I have below table for example. Initial Load, I have data till 15-Jan'17. Highlighted records have been added later. How do I merge the new record? I have created a sample logic for the same. But it seems its not working. Please advise!!!

Product.PNG

1 Solution

Accepted Solutions
its_anandrjs

Gayatri,

Check the attached file for incremental load and on there the initial load script is commented which is for one time if required uncomment those script.

Regards

Anand

View solution in original post

13 Replies
kamal_sanguri
Specialist
Specialist

Hi Gayatri,

Pls refer this qlikview doc. Let me know if you have any question.

kamal_sanguri
Specialist
Specialist

When you run it for the first time, it will load data till 15th Jan and subsequent run will bring remaining data.

prieper
Master II
Master II

Basically correct, however it is not clear, why you change the files.

Typically you would load the data.qvd, determine the last date, concatenate data from Excel beyond this date and store the new dataset into data.qvd.

Code might be:

Sales:

    LOAD * FROM Sales.QVD (QVD);

RecentUpdate:

Load Max([Date Modified]) as MaximumDate Resident Sales;

Let vLastUpdatedDate= Peek('MaximumDate', 0, Sales);

CONCATENATE (Sales) LOAD * FROM [Product.xlsx]

(ooxml, embedded labels, table is Sheet1)

where ([Date Modified])> $(vLastUpdatedDate);

STORE Sales INTO Sales.QVD (QVD);

Peter

qlikview979
Specialist
Specialist

gayatri7
Creator II
Creator II
Author

Have gone through that article and tried implementing the same logic. But it is not working.

qlikview979
Specialist
Specialist

Hi,

i tried with your excel its working fine for me.

Regards

its_anandrjs

Gayatri,

Check the attached file for incremental load and on there the initial load script is commented which is for one time if required uncomment those script.

Regards

Anand

qlikview979
Specialist
Specialist

I tried like below.

Sales:

LOAD [Product ID],

     Item,

     Sales,

     [Store Name],

     [Date Modified]

FROM

(ooxml, embedded labels, table is Sheet1);

store Sales into Incremental.qvd;

//Calculating recent modified date in Sales.qvd

RecentUpdate:

Load Max([Date Modified]) as MaximumDate Resident Sales;

Let vLastUpdatedDate= Date(Peek('MaximumDate', 0, Sales));

drop table Sales;

IncrementalSales:

LOAD [Product ID],

     Item,

     Sales,

     [Store Name],

     [Date Modified]

FROM

(ooxml, embedded labels, table is Sheet1)

where ([Date Modified])> $(vLastUpdatedDate);

store IncrementalSales into Incremental.qvd;

gayatri7
Creator II
Creator II
Author

I just wanted to cross check whether it is only extracting the new record or not. I wanted to store in separate QVD and once verified .. I will concatenate with existing data.

But I am not getting any record in that step.