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

Score big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount

Reply
georgec96
Helper II
Helper II

CALCULATE with Dates filter

Hi guys would be great if someone could help me I'm trying to count every row where due_date <= today() and entry_date <TODAY() - 7

 

I've tried using this functions but it errors

 

count = calculate(count(open_orders[order_number]),open_orders[due_date] <= TODAY(), open_orders[entry_date] < TODAY() - 7)
 
DAXComparison Operations Do Not Support Comparing Values Of Type Date With Type Text
 
Thanks
1 ACCEPTED SOLUTION
johnt75
Super User
Super User

Make sure that the due_date and entry_date columns are both of type Date, at the moment it looks like at least 1 of them is Text.

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

Hi @georgec96 ,
try 

count = calculate(count(open_orders[order_number]),open_orders[due_date] <= TODAY() || open_orders[entry_date] < TODAY() - 7)

Regards

johnt75
Super User
Super User

Make sure that the due_date and entry_date columns are both of type Date, at the moment it looks like at least 1 of them is Text.

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.