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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more

Reply
Aydeedglz
Helper V
Helper V

Countrows only for the values that have a minor date than today

Hi I am trying to create a measure that ONLY will count the rows of the values in column "Date" that are minor than today. That means everything < Today. But the ones that I have created count everything, I don't know where the error is. I am going to display it by costumer.

 

Not working 

VAR A = CALCULATE(COUNTROWS(FILTER(TABLE1,TABLE1[DATE] < TODAY())))
VAR B = IF(VALUES(TABLE1[DATE]) < TODAY(), COUNTROWS(TABLE1), BLANK())
RETURN
COUNTROWS(FILTER(TABLE1,TABLE1[DATE] < TODAY()))
2 REPLIES 2
Anonymous
Not applicable

Hi @Aydeedglz 

 

Unfortunately, your dax works well in my side:

vzhengdxumsft_0-1707113390345.pngvzhengdxumsft_1-1707113411388.png

 

Maybe you can share your data(without sensitive data), or create a sample data.

How to Get Your Question Answered Quickly - Page 13 - Microsoft Fabric Community

 

Best Regards,

Zhengdong Xu

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Idrissshatila
Super User
Super User

Hello @Aydeedglz ,

 

try the following measure

Measure = CALCULATE(COUNTROWS('TABLE1'),'TABLE1'[DATE] < TODAY())


Did I answer your question? Mark my post as a solution! Appreciate your Kudos
Follow me on LinkedIn linkedIn
Vote for my Community Mobile App Idea

Proud to be a Super User!




Helpful resources

Announcements
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!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

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