Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

View all the Fabric Data Days sessions on demand. View schedule

Reply
aignn
Helper II
Helper II

How calculate average for previous month and previous year?

Hi all!

 

Please help me.

 

I have table with 20000 rows.

Every row have column Datetime  and Minutes.

 

I want get average Minutes for previous month and previous year from 01.10.2019.

1. Previous Month (01.09.2019 -01.10.2019)

2. Previous Year (01.10.2018 - 01.10.2019)

 

How to do it right? Thank you advanced

2 REPLIES 2
Anonymous
Not applicable

HI @aignn,

AFAIK, current you can't direct aggregation on date or time values, I'd like to suggest to take a look at the following blog to know more about convert DateTime values and calculate:

Aggregating Duration Time 

Regards,

Xiaoxin Sheng

 

TomMartens
Super User
Super User

Hey @aignn ,

 

please let me direct you to this side: https://www.daxpatterns.com/time-patterns/

 

Regards,

Tom



Did I answer your question? Mark my post as a solution, this will help others!

Proud to be a Super User!
I accept Kudos 😉
Hamburg, Germany

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors
Top Kudoed Authors