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
Aydeedglz
Helper V
Helper V

Convert Special Characters Coma (,) to Point (.)

I am traying to correct the error where I have ( , and . ) in my colum FC gross amount column. I want to repleace the 

(,) to (.) and disppear the (,) because I need to convert from text to number the column in order to do measures and make my query connect.

I have already tried to replace the (,) to (.) with the replace function but is not working, what can I do??

 

Aydeedglz_0-1668530058300.png

 

1 ACCEPTED SOLUTION
speedramps
Super User
Super User

At the top of your Power Query add these steps

 

  • replace values . with nothing

  • replace values , with .
  • change type to fixed deminal number

 

speedramps_0-1668533256029.png

 

Thanks for reaching out for help.

I put in a lot of effort to help you, now please quickly help me by giving kudos.

Remember we are unpaid volunteers and here to coach you with Power BI and DAX skills and techniques, not do the users job for them. So please click the thumbs up and accept as solution button. 

If you give someone a fish then you only give them one meal, but if you teach them how to fish then they can feed themselves and teach others for a lifetime.  I prefer to teach members on this forum techniques rather give full solutions and do their job. You can then adapt the technique for your solution, learn some DAX skills for next time and soon become a Power BI Super User like me. 

One question per ticket please. If you need to extend your request then please raise a new ticket.

You will get a quicker response and each volunteer solver will get the kudos they deserve. Thank you ! 

View solution in original post

7 REPLIES 7
speedramps
Super User
Super User

You are mixing the formats in the same file.

That was not the original question.

If you raise a new ticket with the correct examples then I will be happy to look at it,

but I have closed this problem becarse the problem as decsribed has been resolved.

I am happy to gve free support but I operate on a one problem per ticket basis.

 

speedramps_0-1668537549169.png

 

speedramps
Super User
Super User

In the example you provided the format was

snnpnnncnn   where s is sign and p is period  and c is a comma and n is number
for example -74.505,74

the solution I provide works and I provided an example proving it works, 

 

You have now change the rules to

sncnnn.nn   

for example -6,570.54

 

if you are wanting to combine 

snnpnnncnn and sncnnn.nn   in the same file for example

-74.505,74
-6,570.54

then that is a new problem.

please raise new ticket and provide the correct example data next time,

otherwise it wastes your time and my time.

 

the solution I provide works, I provide an example proving it work, and I will therefore accept the solution

Sorry if that seem harsh but you asked the wrong question but I gave the right answer.

So this problem is closed. Please raise a new ticket wit the correct examples and I will be happy to help.

 

Thanks for reaching out for help.

I put in a lot of effort to help you, now please quickly help me by giving kudos.

Remember we are unpaid volunteers and here to coach you with Power BI and DAX skills and techniques, not do the users job for them. So please click the thumbs up and accept as solution button. 

If you give someone a fish then you only give them one meal, but if you teach them how to fish then they can feed themselves and teach others for a lifetime.  I prefer to teach members on this forum techniques rather give full solutions and do their job. You can then adapt the technique for your solution, learn some DAX skills for next time and soon become a Power BI Super User like me. 

One question per ticket please. If you need to extend your request then please raise a new ticket.

You will get a quicker response and each volunteer solver will get the kudos they deserve. Thank you ! 

 

 

 

speedramps
Super User
Super User

At the top of your Power Query add these steps

 

  • replace values . with nothing

  • replace values , with .
  • change type to fixed deminal number

 

speedramps_0-1668533256029.png

 

Thanks for reaching out for help.

I put in a lot of effort to help you, now please quickly help me by giving kudos.

Remember we are unpaid volunteers and here to coach you with Power BI and DAX skills and techniques, not do the users job for them. So please click the thumbs up and accept as solution button. 

If you give someone a fish then you only give them one meal, but if you teach them how to fish then they can feed themselves and teach others for a lifetime.  I prefer to teach members on this forum techniques rather give full solutions and do their job. You can then adapt the technique for your solution, learn some DAX skills for next time and soon become a Power BI Super User like me. 

One question per ticket please. If you need to extend your request then please raise a new ticket.

You will get a quicker response and each volunteer solver will get the kudos they deserve. Thank you ! 

Is not working 

 

It gives me as a value -657054 

The original value was -6,570.54

So the result should be -6570.54

 

Only deleating (,) not points (.) because I still have decimal number 

 

Power BI

Aydeedglz_0-1668534868619.png

 

Original File (I have correct values like this and incorrect) the files are in a SP, and they are random so I don't want to affect the correct numbers, like this case... Can I only change the errors? 

 

Correct

Aydeedglz_1-1668534986877.png

 

Incorrect

Aydeedglz_3-1668535562461.png

 

 

Is the same with "Fixed Decimal Number"

Aydeedglz_2-1668535106897.png

 

Here is the example to both of them, the data is not separated is in the same column and it keeps growing because daily we update new data

 

   FC gross amount
           171,97
        21.852,30
-653,00
-678,00
-653,00
-653,00
-678,00
-13.880,00
-0,57
-55.701,02
-87.316,78
-74.505,74
-85.341,27
-2.305,43
-2.022,30
-2.467,21
-2.022,30

 

   FC gross amount
-864
-6,570.54
-2,352.00
-15,679.00
-172.77
-129.35
4,597.90
4,566.16
-256.18
-211.13
-70.15
-3,702.52
-734.73
-456.75
8,036.65
speedramps
Super User
Super User

If you have a column containing numbers as text, for example

123

-123

123,456

-123,456

123,456.78

-123,456.78

 

then in Power query simply click the coum and  change type to decimal number

 

If you get an error then that suggests that there are other non numeric characters

 

please copy and paste examples of the raw data table in the chat ... not a screen print ... so we can check it.

 

Remember to hide private data.

 

Thanks for reaching out for help.

I put in a lot of effort to help you, now please quickly help me by giving kudos.

Remember we are unpaid volunteers and here to coach you with Power BI and DAX skills and techniques, not do the users job for them. So please click the thumbs up and accept as solution button. 

If you give someone a fish then you only give them one meal, but if you teach them how to fish then they can feed themselves and teach others for a lifetime.  I prefer to teach members on this forum techniques rather give full solutions and do their job. You can then adapt the technique for your solution, learn some DAX skills for next time and soon become a Power BI Super User like me. 

One question per ticket please. If you need to extend your request then please raise a new ticket.

You will get a quicker response and each volunteer solver will get the kudos they deserve. Thank you ! 

Hi, is still no working because Power BI is converting the (,) to (.) but it doesn't know what to do with the current (.)

 

Aydeedglz_0-1668531145063.png

   FC gross amount
           171,97
        21.852,30
-653,00
-678,00
-653,00
-653,00
-678,00
-13.880,00
-0,57
-55.701,02
-87.316,78
-74.505,74
-85.341,27
-2.305,43
-2.022,30
-2.467,21
-2.022,30
           200,00
            10,82
        52.757,42
-27.526,39
-140,00
-180,00
-280,00
-480,00
-190,00
-450,00
-320,00
-185,00
-185,00
-185,00
         4.174,55
         1.701,67
-320,00
           360,00
-397,92
-0,76
-0,45
-0,87
-0,87
-0,87

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.