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

Announcements
Learn how to migrate to Qlik Cloud Analytics™: On-Demand Briefing!
cancel
Showing results for 
Search instead for 
Did you mean: 
Abhishekb
Contributor III
Contributor III

how to repeat dates till next given date in qlik view

Hi Community,

I have a Quarter End Date. And I want to repeat that date till the next delayed days.

ONLY WORKDAYS SHOULD BE CONSIDERED FOR DELAY DAYS.

Can you help me for this.

Thanks in advance.

 

Labels (3)
1 Solution

Accepted Solutions
Abhishekb
Contributor III
Contributor III
Author

Hi @brokinsa23 ,

Thanks for your solution but I got much more optimized way for this problem.

let vToday = Today();
LET vQuarterEndDate = QuarterEnd('$(vToday)',-1);

Let vDelay1 = $(vDelay);
Let vDelayDate = Date(LastWorkDate('$(vQuarterEndDate)'+1,'$(vDelay1)'));

Load
if(('$(vToday)'= WeekDay('$(vToday)') or '$(vToday)' <> WeekDay('$(vToday)')) and '$(vToday)' <= '$(vDelayDate)',
QuarterEnd('$(vToday)',-1),
'$(vToday)'
) as EndResult

Resident MainTable;

View solution in original post

1 Reply
Abhishekb
Contributor III
Contributor III
Author

Hi @brokinsa23 ,

Thanks for your solution but I got much more optimized way for this problem.

let vToday = Today();
LET vQuarterEndDate = QuarterEnd('$(vToday)',-1);

Let vDelay1 = $(vDelay);
Let vDelayDate = Date(LastWorkDate('$(vQuarterEndDate)'+1,'$(vDelay1)'));

Load
if(('$(vToday)'= WeekDay('$(vToday)') or '$(vToday)' <> WeekDay('$(vToday)')) and '$(vToday)' <= '$(vDelayDate)',
QuarterEnd('$(vToday)',-1),
'$(vToday)'
) as EndResult

Resident MainTable;