Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
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
Luminary Alumni
Luminary Alumni

Hi,

Try like this

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

Hope this helps you.

Regards,

Jagan.

Gysbert_Wassenaar

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