Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi Everyone.
I have a qvd with following type of records.
ID Name Amount
123 james $300
127 John $234
547 Alex $555
New file from sales comes in daily basis with new and corrected records. Therefore I want to update any corrected records and append new records in above qvd.
for example today's sales file contains
ID Name Amount
123 James $265
432 Judy $800
How do you handle above scenerio. Please share example qvw.
thanks
Something like this should work:
MostRecentUpdate:
NOCONCATENATE LOAD ID, max(update_date) as update_date RESIDENT YourTable GROUP BY ID;
INNER JOIN (YourTable)
LOAD * RESIDENT MostRecentUpdate;
DROP TABLE MostRecentUpdate;