Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Find specific dates in the past

Hi all,

Just a quick one about dates. Has anyone ever dealt with finding weekly dates automatically? I am looking to save in a variable last Friday's date for example.

Thanks

1 Solution

Accepted Solutions
kiranmanoharrode
Creator III
Creator III

use this expression,

It will give u last Friday's Date

=if(WeekDay(Today())='Mon',Date(Today()-3),

if(WeekDay(Today())='Tue',Date(Today()-4),

if(WeekDay(Today())='Wed',Date(Today()-5),

if(WeekDay(Today())='Thu',Date(Today()-6),

if(WeekDay(Today())='Fri',Date(Today()-7),

if(WeekDay(Today())='Sat',Date(Today()-8),

if(WeekDay(Today())='Sun',Date(Today()-9))))))))

View solution in original post

3 Replies
kiranmanoharrode
Creator III
Creator III

use this expression,

It will give u last Friday's Date

=if(WeekDay(Today())='Mon',Date(Today()-3),

if(WeekDay(Today())='Tue',Date(Today()-4),

if(WeekDay(Today())='Wed',Date(Today()-5),

if(WeekDay(Today())='Thu',Date(Today()-6),

if(WeekDay(Today())='Fri',Date(Today()-7),

if(WeekDay(Today())='Sat',Date(Today()-8),

if(WeekDay(Today())='Sun',Date(Today()-9))))))))

Not applicable
Author

Thanks I wrote something similar myself but rushed to also ask

kiranmanoharrode
Creator III
Creator III

Welcome Joseph...........