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
Anonymous
Not applicable

Getting FORMAT error

Hi All,

 

Need your help in below situation.

 

This is the code:

SL2 = IF(GBS_TD_REP_for_Gangan[Close time]="","Open",IF(GBS_TD_REP_for_Gangan[Hours]<=GBS_TD_REP_for_Gangan[Priority Duration],"Met","Not Met"))

 

In this code, Close time is Date/Time field and Hours and Priority Duration are Whole number fields.

 

When I am typing above code, below is the attached error I am getting:

Error.JPG

I am unable to figure put how to use value or Format function in my code.

 

Kindly assist.

 

Regards

Abhijit Mishra

1 ACCEPTED SOLUTION
PattemManohar
Community Champion
Community Champion

@Anonymous Give a try with this...

 

SL2 = IF(ISBLANK(GBS_TD_REP_for_Gangan[Close time]),"Open",IF(GBS_TD_REP_for_Gangan[Hours]<=GBS_TD_REP_for_Gangan[Priority Duration],"Met","Not Met"))




Did I answer your question? Mark my post as a solution!

Proud to be a PBI Community Champion




View solution in original post

4 REPLIES 4
v-piga-msft
Resident Rockstar
Resident Rockstar

Hi @Anonymous,

 

By my tests, both of the solution from petrovnikitamai and pattemmanohar should solve your problem.

 

If you have solved your problem, please always accept the replies making sense as solution to your question so that people who may have the same question can get the solution directly.

 

If you still need help, please feel free to ask.

 

Best  Regards,

Cherry

Community Support Team _ Cherry Gao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
petrovnikitamai
Resolver V
Resolver V

try to use blank() instead ""

PattemManohar
Community Champion
Community Champion

@Anonymous Give a try with this...

 

SL2 = IF(ISBLANK(GBS_TD_REP_for_Gangan[Close time]),"Open",IF(GBS_TD_REP_for_Gangan[Hours]<=GBS_TD_REP_for_Gangan[Priority Duration],"Met","Not Met"))




Did I answer your question? Mark my post as a solution!

Proud to be a PBI Community Champion




Anonymous
Not applicable

Thanks for the solutions @petrovnikitamai @PattemManohar @v-piga-msft

 

Below is the code, which also gave the same result:

SL2 = IF(FORMAT(GBS_TD_REP_for_Gangan[Close time],"dd mm yy")="","Open",IF(GBS_TD_REP_for_Gangan[Hours]<=GBS_TD_REP_for_Gangan[Priority Duration],"Met","Not Met"))

 

Regards

Abhijit Mishra

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.