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

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
labuser1235
Helper IV
Helper IV

Constant count through out the time line

Hi All,

 

I would like to have a DAX measure where it shows the count of entire rows in a table and that being constant through out the time line.

 

For example in the given table1 image there are 8 rows and I want 8 to be constant throug the time line i.e from min(datetable[date) to max(table1[date sold]). So when we put that in a line visual its more like a straight line.

 

I can achieve it using a calculated column, however, I would need only a DAX Measure which can full fill this. 

 

Screenshot 2020-07-16 at 5.42.52 PM.png

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@labuser1235 ,

New measures =CALCULATE(countrrows(Table),ALLCROSSFILTERED(Table))

 

https://www.linkedin.com/pulse/five-recent-power-bi-functions-you-should-use-more-often-amit-chandak...

Join us as experts from around the world come together to shape the future of data and AI!
At the Microsoft Analytics Community Conference, global leaders and influential voices are stepping up to share their knowledge and help you master the latest in Microsoft Fabric, Copilot, and Purview.
️ November 12th-14th, 2024
 Online Event
Register Here

View solution in original post

4 REPLIES 4
amitchandak
Super User
Super User

@labuser1235 ,

New measures =CALCULATE(countrrows(Table),ALLCROSSFILTERED(Table))

 

https://www.linkedin.com/pulse/five-recent-power-bi-functions-you-should-use-more-often-amit-chandak...

Join us as experts from around the world come together to shape the future of data and AI!
At the Microsoft Analytics Community Conference, global leaders and influential voices are stepping up to share their knowledge and help you master the latest in Microsoft Fabric, Copilot, and Purview.
️ November 12th-14th, 2024
 Online Event
Register Here

@amitchandak Thank you so much. It worked like charm 🙂

az38
Community Champion
Community Champion

Hi @labuser1235 

try a measure like

CALCULATE(COUNTROWS(table1), ALL(table1[date sold]) )

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

@az38 Thank you so much for your quick response. 

All(table1[dates old]) is giving me only 1 as constant line on that particular day. However, when tried allselected it worked perfectly fine. 

 

Screenshot 2020-07-17 at 10.39.02 PM.png

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

Jan25PBI_Carousel

Power BI Monthly Update - January 2025

Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.