Skip to main content
Announcements
Live today at 11 AM ET. Get your questions about Qlik Connect answered, or just listen in. SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

trend weekly count 30 last days

Hello community,

I want to calculate the 30 last days with trend weekly I calculated the last 30 days on script

and I used this formula

sum({<[Calculation Method]={'WTD : -30D : P'},

[Report Date]={'>=$(=WeekStart(Max([Report Date]),-24))<=$(=WeekEnd(Max([Report Date])))'}>}[Qty Net Sold])

but the result is on my graph I have only the count of last week and not the last 30 days .

Thank you in advance .

1 Reply
MK9885
Master II
Master II

sum({<

[Report Date] = {"$(='>=' & Date(Max([Report Date]) - 30, 'MM/DD/YYYY') & '<=' & Date(Max([Report Date]), 'MM/DD/YYYY'))"},

Month, Year,    Quarter,   Week

>}[Qty Net Sold])

This would give you last 30 days of data from the max date you have in Report Date.