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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
NickzNickz
Helper IV
Helper IV

Error MdxScritp(Model)(155,63) > Cannot convert value "-" of type Text to type Numeric/Date

Hi .. 

I have below testing measures and can view the result...

Migration (RM) = 
VAR _Result = 
    CALCULATE(
        SUM( fin_migration[Migration (M)] ),
        fin_migration[Date] = MAX( fin_migration[Date] ),
        fin_migration[Month] = MAX( fin_migration[Month] )
    )

RETURN
IF(ISBLANK(_Result),"0.00",_Result)

 

However, when I try to change from "0.00" to "-" , I received  an error as below:

 

MdxScritp(Model)(155,63) > Cannot convert value "-" of type Text to type Numeric/Date

 

What should I do next to resolve the problem? ...

Regards,

NickzNickz

 

2 REPLIES 2
johnt75
Super User
Super User

A measure can only return values of a single type, so everything will need to be numeric or everything will need to be text. If you want to return the values as text you could use the FORMAT function, otherwise you'll need to keep the measure returning blank or 0 when the result is blank.

Hi @johnt75 ,

 

Both my measure and tables are in decimal numbers.

Other tables were just okay... No problem. ..

 

Regards,

NickzNickz

 

 

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.