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

Get certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now

Reply
third_hicana
Helper IV
Helper IV

If blank return a "text"

 Hi DAX Experts. Do you know what is wrong with my Dax formula. So here's the logical test.

1. If Resource List end date is today and prior,then it will return as "Contract End".

2. If Resource List end date is not today but on a later date and beyond, then return a text as "Ongoing"

3. If Resource List end date is blank, then return a text as also "Ongoing".

 

My error is if resource list end date is blank the return text is "Contract End" which is supposed to be "Ongoing".

Thank you for your help. 😞

 

583239cc-6a09-4287-bfe6-fcd3862cf3a0photo.jpeg

1 ACCEPTED SOLUTION

@third_hicana 

Please try

Resource Status =
IF (
COALESCE ( 'Resource List'[End Date], TODAY () ) < TODAY (),
"Contract End",
"Ongoing"
)

View solution in original post

4 REPLIES 4
tamerj1
Super User
Super User

Hi @third_hicana 

can you please compy/paste the formula so I can edit?

Hi @tamerj1  Here it is. Thank you.

Resource Status = IF('Resource List'[End Date] < TODAY(),
"Contract End",
IF('Resource List'[End Date] >= TODAY(),
"Ongoing", "Ongoing"))

@third_hicana 

Please try

Resource Status =
IF (
COALESCE ( 'Resource List'[End Date], TODAY () ) < TODAY (),
"Contract End",
"Ongoing"
)

Hi @tamerj1 

It works now. Thank you very much. 🙂

Helpful resources

Announcements
November Carousel

Fabric Community Update - November 2024

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

Live Sessions with Fabric DB

Be one of the first to start using Fabric Databases

Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.

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! Early Bird pricing ends December 9th.

Nov PBI Update Carousel

Power BI Monthly Update - November 2024

Check out the November 2024 Power BI update to learn about new features.