Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Filling Date Gaps During Load Set Frequency

I have been scouring the discussion groups on filling date gaps. My need is that I need to generate a date based on a frequency.

So I have a start date:      01/01/2014

an End Date:                    12/31/2014

and a frequency of:          30 days

Value                              5


I want to be able to populate a date every days up to the end date, but not everyday. I know the 30 days don't translate to the dates below, this is just an example.


2/1/2014

3/1/2014

4/1/2014 ...


Using the other methods in the groups, I see how to fill in every day, but that is not what I was shooting for.


I have attached an example.


Any help would greatly be appreciated and thank you in advance.

Labels (1)
1 Solution

Accepted Solutions
swuehl
Champion III
Champion III

Maybe like

Table1:

LOAD

ID,StartDate,EndDate,Value,Frequency

Inline

[

ID,StartDate,EndDate,Value,Frequency

1,01/01/2014,12/31/2014,5,30

2,01/01/2013,12/31/2014,55,30

3,01/01/2012,12/31/2014,555,60

4,01/01/2011,12/31/2014,5555,60

];

Table2:

Load ID,

Date(StartDate + (IterNo()-1)*Frequency) as GapDate

Resident

Table1

While (IterNo()-1)*Frequency <= EndDate - StartDate

;

View solution in original post

2 Replies
swuehl
Champion III
Champion III

Maybe like

Table1:

LOAD

ID,StartDate,EndDate,Value,Frequency

Inline

[

ID,StartDate,EndDate,Value,Frequency

1,01/01/2014,12/31/2014,5,30

2,01/01/2013,12/31/2014,55,30

3,01/01/2012,12/31/2014,555,60

4,01/01/2011,12/31/2014,5555,60

];

Table2:

Load ID,

Date(StartDate + (IterNo()-1)*Frequency) as GapDate

Resident

Table1

While (IterNo()-1)*Frequency <= EndDate - StartDate

;

Anonymous
Not applicable
Author

That is a winner for sure !!! Thank you.