Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Announcements
QlikView Fans! We’d love to hear from you.
Share your QlikView feedback with the product team… Click here to participate in our 5-minute survey.
Rules, plus terms and conditions, can be found here.
kumarreddy257
Contributor

incrmental load

Hi

I have a requirement like below. I have an QVD which is 3 months data till yesterday and daily I will get an excel file as a data and it will be override on daily base with the new data. Now here is situation for me

I want  add data to existing QVD with the new data on daily basis.Suppose if I get an excel data today, it has to check November month QVD data and with ID columns(there time stamp or modified date column) and replaced with new data. In the same way if I run this load on December it has to check only December data and modified with excel data.

Here I don't have time stamp column and only having ID column

Please suggest me how to proceed on this.

Regards,

Kumar

10 Replies
t_chetirbok
Valued Contributor

Re: incrmental load

Hi, TEST.qvd contains all data, TEST.xlsx contains only today data.

You can load data from qvd without "today" data and concatenate data from xslx with generate field.

Hope, It's helpfull.

kumarreddy257
Contributor

Re: incrmental load

Hi,

Thanks for ur reply and not able to open this document

Can you send me again.

Regards,

Kumar

t_chetirbok
Valued Contributor

Re: incrmental load

Sorry)

kumarreddy257
Contributor

Re: incrmental load

Thanks again for sharing valuable information. Here in my QVD I don't have date column and one more thing it has to check the qvd data on monthly wise. I mean if you run in November month it has to check to check November data and modified that data. If run in December it should check in December and adds to that QVD file.

In my QVD I have columns data like

yearmonth     location   ID

201509

.

.

.

201511            US         1

201511             UK        2

201511             AUS      3

Suppose today i got excel like

yearmonth    location ID

201511          HKG    1

My final output should be like

yearmonth     location   ID

201509

.

.

.

201511            HKG         1

201511             UK        2

201511             AUS      3

So US is replaced with HKG.

So if I run QVD script in December with new data it has to check with December QVD data and any changes are there in QVD it has to modified and should create final QVD.

Once again thanks a lot for ur valuable information

Regards,

Kumar

t_chetirbok
Valued Contributor

Re: incrmental load

ok, try this code

Table:

LOAD yearmonth, location, id, AutoNumber(yearmonth&id) as NUM

FROM

TEST.xlsx

(ooxml, embedded labels, table is Лист1);

load

yearmonth, location, id, AutoNumber(yearmonth&id) as NUM

from  TEST.qvd(qvd)

where not Exists(NUM,AutoNumber(yearmonth&id) )

;

kumarreddy257
Contributor

Re: incrmental load

Hi ,

As you suggested, I tried to change the logic and ran the QVD loader script. But there is no change in that QVD.

It is updating the values.

Regards,

Kumar

t_chetirbok
Valued Contributor

Re: incrmental load

I write in the script

//store Table into TEST.qvd(qvd);

You should uncomment this line

mohammadkhatimi
Valued Contributor

Re: incrmental load

Hi...

PFA..

Regards,

Mohammad

kumarreddy257
Contributor

Re: incrmental load

Hi Mohammad,

Thanks for sharing valuable information. My requirement is not like incremental load. Here it it should modify only current month records and it should not modify any records withe same id  in previous months records.

Community Browser