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

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
AW1976NOVA
Post Patron
Post Patron

How change data type from Character to Percentage while specifying decimal

Hi,

 

I have a table I'm bringing in to Power BI.  One of the columns that is being brought in to Pwer BI is a decimal number...but in Character Format.  The issue is, when I convert these Characters to percentages....the new values do not make any sense and the decimal place is incorrect.  I'm trying to avoid adding a calculated column because the table is huge and I do not want to make the file any larger than it already is.  Here is an example of the data:

 

Name     Value

Andy      7.1

Bob        8.2

Dan        1.3

 

WhenI convert the value column from ABC to % in Edit Queries this is the result:

 

Name      Value

Andy       710%

Bob         820%

Dan        130%

 

I want the result to be:

 

Name       Value

Andy        7.1%

Bob          8.2%

Dan          1.3%

 

I need these values to be true percentages because I'm building out other metrics that are dependant on these values being actual percentages.

 

Is there a way to specify the decimal place in Edit Query without having to create a custom column?

 

 

 

 

Thank you

1 ACCEPTED SOLUTION
FrankAT
Community Champion
Community Champion

Hi @AW1976NOVA 

divide the values by 100 and format this value in percent.

With kind regards from the town where the legend of the 'Pied Piper of Hamelin' is at home
FrankAT (Proud to be a Datanaut)

View solution in original post

5 REPLIES 5
amitchandak
Super User
Super User

@AW1976NOVA , This already in %, so you can divide it by 100. Or you can keep it only as decimal

 

[Value]/100

Right.  I was hoping there was some kind of transformation already built n Power BI so I could avoid creating a new column with the expression [Value] / 100 but I don't think that is a capability.

@AW1976NOVA I am fairly certain that you can use the math operations to perform the math on the same column. Select column, choose divide from the math operations and enter 100. In Power Query Editor.



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
Power BI Cookbook Third Edition (Color)

DAX is easy, CALCULATE makes DAX hard...
FrankAT
Community Champion
Community Champion

Hi @AW1976NOVA 

divide the values by 100 and format this value in percent.

With kind regards from the town where the legend of the 'Pied Piper of Hamelin' is at home
FrankAT (Proud to be a Datanaut)

Greg_Deckler
Super User
Super User

@AW1976NOVA In Power Query, divide those values by 100 and then display them as percentages.



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
Power BI Cookbook Third Edition (Color)

DAX is easy, CALCULATE makes DAX hard...

Helpful resources

Announcements
Europe Fabric Conference

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

AugPowerBI_Carousel

Power BI Monthly Update - August 2024

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

August Carousel

Fabric Community Update - August 2024

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