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

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes! Register now.

Reply
inna_sysco
Helper II
Helper II

Decoding HTML symbols into actual symbols in Power BI

Hello everyone!
I am trying to load HTML data (special characters, links, etc.) from Azure Database to Power BI.
During my research, I found many suggestions on how to do this, but, unfortunately, none of them work for me ...
Am I missing something?
The last solution I tried  - https://stackoverflow.com/questions/65105454/decoding-html-symbol-decimal-numbers-into-actual-symbol...
But after all, I have such a result:

 

inna_sysco_0-1614851368207.png

 

 
 

Any suggestions?

I will be very grateful for any ideas!

1 ACCEPTED SOLUTION
PhilipTreacy
Super User
Super User

Hi @inna_sysco 

 

Download sample PBIX file with solution

 

The problem here is that the symbol has been 'double-encoded'.  For example the code for the HTML symbol less than < is &lt; but that has been encoded as &amp;lt; because the & sign itself has been encoded as &amp; 

To fix this you need to Replace Values on the column to switch &amp; back to just &

html1.png

html2.png

 

Then you can use Html.Table to decode

html3.png

 

Here's the full example query that you can find in my PBIX file above

let
    Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45Wiik1MDAyS8wtsM4psS5A8NJLrJViYwE=", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [VALUE = _t]),
    #"Replaced Value" = Table.ReplaceValue(Source,"&amp;","&",Replacer.ReplaceText,{"VALUE"}),
    #"Added Custom" = Table.AddColumn(#"Replaced Value", "Custom", each Html.Table([VALUE],{{"HtmlDecoded",":root"}})),
    #"Expanded Custom" = Table.ExpandTableColumn(#"Added Custom", "Custom", {"HtmlDecoded"}, {"HtmlDecoded"})
in
    #"Expanded Custom"

 

Regards

Phil

 



Did I answer your question? Then please mark my post as the solution.
If I helped you, click on the Thumbs Up to give Kudos.


Blog :: YouTube Channel :: Connect on Linkedin


Proud to be a Super User!


View solution in original post

3 REPLIES 3
PhilipTreacy
Super User
Super User

@inna_sysco 

You're welcome.

Phil



Did I answer your question? Then please mark my post as the solution.
If I helped you, click on the Thumbs Up to give Kudos.


Blog :: YouTube Channel :: Connect on Linkedin


Proud to be a Super User!


PhilipTreacy
Super User
Super User

Hi @inna_sysco 

 

Download sample PBIX file with solution

 

The problem here is that the symbol has been 'double-encoded'.  For example the code for the HTML symbol less than < is &lt; but that has been encoded as &amp;lt; because the & sign itself has been encoded as &amp; 

To fix this you need to Replace Values on the column to switch &amp; back to just &

html1.png

html2.png

 

Then you can use Html.Table to decode

html3.png

 

Here's the full example query that you can find in my PBIX file above

let
    Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45Wiik1MDAyS8wtsM4psS5A8NJLrJViYwE=", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [VALUE = _t]),
    #"Replaced Value" = Table.ReplaceValue(Source,"&amp;","&",Replacer.ReplaceText,{"VALUE"}),
    #"Added Custom" = Table.AddColumn(#"Replaced Value", "Custom", each Html.Table([VALUE],{{"HtmlDecoded",":root"}})),
    #"Expanded Custom" = Table.ExpandTableColumn(#"Added Custom", "Custom", {"HtmlDecoded"}, {"HtmlDecoded"})
in
    #"Expanded Custom"

 

Regards

Phil

 



Did I answer your question? Then please mark my post as the solution.
If I helped you, click on the Thumbs Up to give Kudos.


Blog :: YouTube Channel :: Connect on Linkedin


Proud to be a Super User!


@PhilipTreacy , thank you very much for your answer and detailed instructions!
This completely solved my problem!

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 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
Top Kudoed Authors