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
cubedweller
Regular Visitor

DAX formula for dates

I am new to DAX.

I would like to create a variable called Completed Past Due.
How would I write this logic as a DAX expression?
if (task_due_date < task_completion_date and
task_completion_date is not missing and
status = "completed")
then "Yes" else "No"

 

Thank you.

 

1 ACCEPTED SOLUTION
deldersveld
Resident Rockstar
Resident Rockstar

Something along the lines of =SWITCH(TRUE(), Table[task_due_date] < Table[task_completion_date] && NOT(ISBLANK(Table[task_completion_date])) && Table[status]="completed", "Yes", "No")

View solution in original post

1 REPLY 1
deldersveld
Resident Rockstar
Resident Rockstar

Something along the lines of =SWITCH(TRUE(), Table[task_due_date] < Table[task_completion_date] && NOT(ISBLANK(Table[task_completion_date])) && Table[status]="completed", "Yes", "No")

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