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

Announcements
Join us to spark ideas for how to put the latest capabilities into action. Register here!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Dates

Hello,

I need to extract from my calendar the last sunday of the month

how can i do this?

tnks!

1 Solution

Accepted Solutions
swuehl
MVP
MVP

May similar to this?

TempCalendar:

LOAD Date(makedate(2013)+recno()) as TempDate

AutoGenerate 500;

Calendar:

LOAD *, weekday(LastSunday) as Test;

LOAD Date(max(if(weekday(TempDate)=6,TempDate))) as LastSunday

Resident TempCalendar

group by monthstart(TempDate);

View solution in original post

2 Replies
swuehl
MVP
MVP

May similar to this?

TempCalendar:

LOAD Date(makedate(2013)+recno()) as TempDate

AutoGenerate 500;

Calendar:

LOAD *, weekday(LastSunday) as Test;

LOAD Date(max(if(weekday(TempDate)=6,TempDate))) as LastSunday

Resident TempCalendar

group by monthstart(TempDate);

Not applicable
Author

Tnks Swuehl!!