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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

create count over 12 months from the date

Hi The community,

I don't understand mistake.

I want to create a graphiq with this expression :

= COUNT({$<Date={">=$(=MonthStart(AddMonths(Max(MoisDateCreationOT),-12)))"}*{"<$(=MonthEnd(Max(MoisDateCreationOT)))"}>}ID_OT)))

but screen displays anything

I want to display ID_OT by month and more precisely over 12 months from the date

How can I do?

Thanks a lot

2 Replies
jagan
Partner - Champion III
Partner - Champion III

Hi,

Try like this

= COUNT({$<Date={">=$(=MonthStart(Max(MoisDateCreationOT),-12))<$(=MonthEnd(Max(MoisDateCreationOT)))"}>}ID_OT)

Hope this helps you.

Regards,

Jagan.

Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

1. Try

COUNT({$<Date={">=$(=MonthStart(AddMonths(Max(MoisDateCreationOT),-12)))<$(=MonthEnd(Max(MoisDateCreationOT)))"}>}ID_OT)))


2. If you want to use month as dimension and show the count as a rolling count over 12 month you can't use set analysis. You can try using an AsOf table. See this document for more information: Calculating rolling n-period totals, averages or other aggregations


talk is cheap, supply exceeds demand