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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more

Reply
Aydeedglz
Helper V
Helper V

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

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 want to combine two types of data the "correct" (-6,570.54) and those that are making my error "incorrect" (-74.505,74)

snnpnnncnn and sncnnn.nn   in the same file for example

-74.505,74
-6,570.54

 

I have tried:

  • replace values . with nothing
  • replace values , with .
  • change type to fixed decimal number

And it works for this case -74.505,74

 

BUT -6,570.54 changes to -657054 it erase the decimal 

 

Case 1 (Errors -74.505,74)

Aydeedglz_0-1668537954128.png

Aydeedglz_1-1668537992718.png

 

 

Case 2 (Correct number -6,570.54) When using solution to error 

 

Aydeedglz_3-1668538050267.png

Aydeedglz_2-1668538033563.png

 

 

 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @Aydeedglz ,

You can consider pressing '.' Split the columns so that you get two columns, one for the integer part and one for the decimal part, replacing the ',' in the decimal part and finally combining them into one column.

vcgaomsft_0-1668580706330.png

vcgaomsft_1-1668580735993.png

vcgaomsft_2-1668580924241.png

let
    Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45W0jXTMTU30DM1UYrVAfLMTfRMDUx1zIHcWAA=", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [Column1 = _t]),
    #"Changed Type" = Table.TransformColumnTypes(Source,{{"Column1", type text}}),
    #"Split Column by Delimiter" = Table.SplitColumn(#"Changed Type", "Column1", Splitter.SplitTextByDelimiter(".", QuoteStyle.Csv), {"Column1.1", "Column1.2"}),
    #"Replaced Value" = Table.ReplaceValue(#"Split Column by Delimiter",",","",Replacer.ReplaceText,{"Column1.2"}),
    #"Added Custom" = Table.AddColumn(#"Replaced Value", "Custom", each [Column1.1] & "." & [Column1.2]),
    #"Removed Columns" = Table.RemoveColumns(#"Added Custom",{"Column1.1", "Column1.2"})
in
    #"Removed Columns"

Best Regards,
Gao

Community Support Team

 

If there is any post helps, then please consider Accept it as the solution  to help the other members find it more quickly. If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!

How to get your questions answered quickly -- How to provide sample data

View solution in original post

1 REPLY 1
Anonymous
Not applicable

Hi @Aydeedglz ,

You can consider pressing '.' Split the columns so that you get two columns, one for the integer part and one for the decimal part, replacing the ',' in the decimal part and finally combining them into one column.

vcgaomsft_0-1668580706330.png

vcgaomsft_1-1668580735993.png

vcgaomsft_2-1668580924241.png

let
    Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45W0jXTMTU30DM1UYrVAfLMTfRMDUx1zIHcWAA=", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [Column1 = _t]),
    #"Changed Type" = Table.TransformColumnTypes(Source,{{"Column1", type text}}),
    #"Split Column by Delimiter" = Table.SplitColumn(#"Changed Type", "Column1", Splitter.SplitTextByDelimiter(".", QuoteStyle.Csv), {"Column1.1", "Column1.2"}),
    #"Replaced Value" = Table.ReplaceValue(#"Split Column by Delimiter",",","",Replacer.ReplaceText,{"Column1.2"}),
    #"Added Custom" = Table.AddColumn(#"Replaced Value", "Custom", each [Column1.1] & "." & [Column1.2]),
    #"Removed Columns" = Table.RemoveColumns(#"Added Custom",{"Column1.1", "Column1.2"})
in
    #"Removed Columns"

Best Regards,
Gao

Community Support Team

 

If there is any post helps, then please consider Accept it as the solution  to help the other members find it more quickly. If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!

How to get your questions answered quickly -- How to provide sample data

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

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.

Top Solution Authors