Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I just wanna ask how to perform this kind of scenario in Incremental Load:

Attached is the one that I followed in creating Incremental Load (Thanks to Mr.
and his QV cookbook)
up!
There's not really a remarkable difference when loading the the separate QVDs into the QVW over loading a huge single one. When it is about grabbing SQL data, incremental load it is a large time saver. Of course its much more time saving to load the last day or month and store it into a QVD file than it would be loading the whole data table on every reload - assuming a large data table in sql
Sir, your answer didn't help me at all..
Oh sorry, i completely misread your question and thought you'd ask for the performance.
I checked your demo file and it seems correct except the inner join statement in the Incremental Load tab and the table tab seems to be futile.
why is it incorrect? the inner joins there handles deleted data. the table that i loaded there is just for example purposes.
Thanks!
Ah ok, because of my own practice i did not expect a sql table where data gets completely deleted. We got state flags. In your case this is of course correct.
If you want to store the QVDs per month you have to split the loaded data. If not just ignore the below code
MonthTable:
load year(dss_update_time)&num(Month(dss_update_time),00) as UserMonth,
sum(1) as FlagField
resident $(vTableName)
group by year(dss_update_time)&num(Month(dss_update_time),00);
for i=0 to NoOfRows('UserMonth')-1
let vUserMonth = peek('UserMonth', $(i), UserMonth);
UserPerMonth:
Noconcatenate load *
resident $(vTableName)
where year(dss_update_time)&num(Month(dss_update_time),00) = '$(vUserMonth)'
;
if(FileSize('$(vQvdPath)' & '$(vQvdName)'&'$(vUserMonth)') > 0, -1, 0);
Concatenate(UserPerMonth)
LOAD *
From $(vQvdPath)$(vQvdName)$(vUserMonth) (qvd)
Where not Exists($(vPK));
---Join Statement---
Store UserPerMonth into $(vQvdPath)$(vQvdName)$(vUserMonth);
drop table UserPerMonth;
next;
drop table $(vTableName);
drop table MonthTable;
exit script;
please disregard any syntax errors ![]()