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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

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
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.