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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Convert minus number

How can I convert -1.5 of type text to number?  I tried with value() but getting error :

 

Cannot convert '-1.5' of type text to type number.

 

 

1 ACCEPTED SOLUTION
Aditya_Meshram
Solution Supplier
Solution Supplier

You can use the CONVERT() function keeping the second argument as Double. 

For Example: 

ConvertToDecimal = CONVERT(ALL('Table1'[Column1]),DOUBLE)
 

View solution in original post

5 REPLIES 5
Aditya_Meshram
Solution Supplier
Solution Supplier

You can use the CONVERT() function keeping the second argument as Double. 

For Example: 

ConvertToDecimal = CONVERT(ALL('Table1'[Column1]),DOUBLE)
 
prashpawar
Frequent Visitor

Hello @Anonymous 

Please try in tranform Data ( Query Editor )
change datatype of this particular colunm to number

 

prashpawar_0-1621931648978.png

 

 

Anonymous
Not applicable

Unfortunately it is not possible to do this. I read data from a table which other values in this table works fine for other measures. I should do this seperately with dax.

amitchandak
Super User
Super User

@Anonymous , Try to change the data type to number(Power Query). Is it giving error

Anonymous
Not applicable

Can you explain more with example?

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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