Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Min_Max:
Load
Min("Created Date") as MinDate,
Max("Created Date") as MaxDate
Resident TradeNameRequest;
Let vMinDate = num(Peek('MinDate',0,'Min_Max'));
Let vMaxDate = num(Peek('MaxDate',0,'Min_Max'));
Trace $(vMAxDate);
Drop Table Min_Max;
Dateranges:
Load
$(vMinDate) + IterNo()-1 as datenum,
Date($(vMinDate) + IterNo()-1) as Tempdate
AutoGenerate 1 while $(vMinDate) + IterNo()-1 <= $(vMaxDate);
MasterCalender:
Load
Tempdate as "Created Date",
Date(Tempdate) as Created_Date,
year(Tempdate) as Year,
'Q'&Ceil(Month(Tempdate)/3) as Quarter,
Month(Tempdate) as Month,
Day(Tempdate) as Day,
week(Tempdate) as week
Resident Dateranges Order by Tempdate asc ;
Drop Table Dateranges;
Could it be that your Dateranges table never gets created?
Do get the expected output to the Dateranges table?