Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
As part of my script load I have data with a start and end date(eg, Start-1st Jan 2014, End-1st Jan 2015). I'd like to load this record against all dates between these dates, so in Qlikview if I was to select June 2014 for example, this record would be included.
Is there a simple way to autogenerate the additional dates as part of the load script?
EG, Data looks like ABC, 01Jan2014, 01Jan2015.
I want to load into Qlikview...
ABC,01Jan2014
ABC,02Jan2014
ABC,03Jan2014
ETC....
ABC,31Dec2014
ABC,01Jan2015
Hope that makes sense and thanking your in advance.
Kind Regards,
Warren
Let vMinDate = NUM(Date('01/01/2014'));
Let vMaxDate = NUM(Date('01/01/2015'));
Load
Date(Date#(Date($(vMinDate) + IterNo() - 1),'DD/MM/YYYY'),'DDMMMYYYY') as Date
AutoGenerate 1
While $(vMinDate) + IterNo() - 1 <= $(vMaxDate);
Join
Load 'ABC' as Data AutoGenerate 1;
Perfect - Thank you!
Many thanks…
Kindly close the thread by selecting appropriate answer so that others can also use it...