Showing results for 
Search instead for 
Did you mean: 
Regular Visitor

DAX measure to show the rolling total for each month based on column values in a matrix visual

Hello All,


I have a requiremet to show the count of old meter and new meter in a single matrix. Old meter count will be decreasing  and new meter count will be increasing on daily basis.  I am using direct query and not storing any data inside Power BI. Data from table itself coming as rolling total on daily basis (Sample data from the table provided below).


I wanted to display the min of old count and max of new count on monthly basis as shown below. Example for the month of october in matrxi, Count of old meter is 9000 and new meter is 2000. In november, Old meter is 5000 and new meter is 6000. Expected output is provided below.


I am facing challenges in creating a DAX measure to show the old and new count as metioned in matrix visual. I would appreciate any suggestions/input in showing the old and new count in a matrix.


Data from Input table

DateOld Meter CountNew Meter Count



Expected Output

MetersOctNov Dec
Old Meter Count900050001000
New Meter Count2000600010000


Community Champion
Community Champion

Hi @manojsv19 

try new table

NewTable = summarize('Table1';Table1[Date].[Month];"Old Meter Count";min('Table1'[Old Meter Count]);"New Meter Count";MAX('Table1'[New Meter Count]))

are sure you need output exactly as you showed above? it will not be so easy 🙂

do not hesitate to give a kudo to useful posts and mark solutions as solution


do not hesitate to give a kudo to useful posts and mark solutions as solution



Thank you for the inputs!!


Yes, my requirement is to show the output as provided in the example and am using direct query. I wanted to get the summarize count from the query and don't want to do the aggregration at Power BI.


Let me konw for any additional information.

Helpful resources

PBI Sept Update Carousel

Power BI September 2023 Update

Take a look at the September 2023 Power BI update to learn more.

Learn Live

Learn Live: Event Series

Join Microsoft Reactor and learn from developers.

Dashboard in a day with date

Exclusive opportunity for Women!

Join us for a free, hands-on Microsoft workshop led by women trainers for women where you will learn how to build a Dashboard in a Day!

MPPC 2023 PBI Carousel

Power Platform Conference-Power BI and Fabric Sessions

Join us Oct 1 - 6 in Las Vegas for the Microsoft Power Platform Conference.

Top Solution Authors
Top Kudoed Authors