Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

How to handle incremental load ?

Hi All,

I have to implement incremental load and I have following material master on  FTP now how to handle incremental load? Here itemnumber is a primary key

Material_Master:

   LOAD

  MATERIAL,

     COLOR,

     SIZE,

     MATERIAL&COLOR&SIZE as itemnumber,

     [Size Group],

     Description,

     COMPOSITION,

     BRANDCD,

     BRAND,

     SEASON,

     SEASONDESC,

     THEME,

     DELYCODE,

     GENDER,

     IF(GENDER ='LADIES', 'WOMEN', IF(GENDER='MENS','MENS',  IF(GENDER='BOYS' or GENDER='GIRLS' or GENDER='BABY','KIDS', GENDER))) as Gender_Revised,

     ProductHierarchy,

     MaterialGroup,

     [Core/Fashion],

     FIT,

     PATTERN,

     [Key/NonKey],

     RANGE,

     ORIGIN,

     [Top/Bottom],

     SLEEVE,

     NECK,

     WEATHER,

     OCCASSION,

     CustomDesc,

     MaterialGrp4,

     MGRP4DESC,

     EAN,

     ALTEAN,

     PurchaseGroup,

     PurchaseGroupDesc,

     CATEGORY,

     SUBCAT,

     BASECOMP,

     MaterialType as Promotional_1,

     ValuationClass,

     COST,

     MRP as MRP_INR,

     if (MRP <1000, '<1000', if (MRP <2000, '1000-2000',if (MRP <3000, '2000-3000',if (MRP <4000, '3000-4000',if (MRP <5000, '4000-5000',if (MRP <6000, '5000-6000', '>6000')))))) as [MRP Bucket]


FROM

(qvd)

where Exists itemnumber;

21 Replies
crusader_
Partner - Specialist
Partner - Specialist

Why are I trying to assume something instead of checking qvd file? Open file, check script - see result: easy...

What is correct data? You're not getting expected result - most likely yes, but I can't tell what you see sitting on opposite side of the world.

baarathi
Creator III
Creator III

Hi Saksham, sakshamkaul

Let vQVDExists = not IsNull(QvdCreateTime('lib://Folder/QVDs/Xyz.qvd'));


If $(vQVDExists) THEN

    Xyz:

     LOAD

        ID,

    Type;

    SQL SELECT ID,

    Type

FROM Xyz

    where CreatedOn >= '$(vLastReloadDate)' OR UpdatedOn >= '$(vLastReloadDate)';

   

    Concatenate

   

    LOAD

        ID,

    Type

    FROM [lib://Folder/QVDs/Xyz.qvd]

    (qvd) where not Exists(ID);

Else


   Xyz:

    LOAD ID,

    Type;

    SQL SELECT ID,

    Type

    FROM Xyz;

End If



Try this one. Please end the thread after getting the answer by marking correct answer.