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: 
Anonymous
Not applicable

Sum Week

Working on a measure that would show me total sales from last full  week based on todays date.  So far I have this expression but it is not functioning: 

sum(aggr(sum(distinct{$<[completed_date.autoCalendar.Week]={"$(=Week(Today(1) )"}>}(order_total)), order_id))

Any help on with this expression is appreciated.  Thanks in advance

4 Replies
sunny_talwar

May be because you are missing a parenthesis

Sum(Aggr(Sum(DISTINCT {$<[completed_date.autoCalendar.Week] = {"$(=Week(Today(1)))"}>} order_total), order_id))

Anonymous
Not applicable
Author

Made that change, but still not functioning.  Thanks though, probably not going to hurt to have the correct amount of parenthesis in espression.

sunny_talwar

Can you show the script for the derived calendar?

Anonymous
Not applicable
Author

Not sure how to do that, maybe I don't have access to it?