Hi,
What is the best way to remove HTML tags from a very large text field in M or DAX?
Currently I am using Html.Table but my table contains over 20 lakh records with very large text (exceeding 300 characters) and it takes more than 0.5 hour to load up after I click "Close & Apply". Its very frustrating to wait this long for a simple modification. Can it be moved to DAX? Any ideas on how to do it?
Thanks
Nirmit
Solved! Go to Solution.
Hi @nirmit27 ,
I created some data:
Here are the steps you can follow:
1. Create calculated column.
Column =
PATHITEM(
SUBSTITUTE(
SUBSTITUTE([Html], ">", "|"),
"</","|"), 2,TEXT)
2. Result:
Best Regards,
Liu Yang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Hi @nirmit27 ,
I created some data:
Here are the steps you can follow:
1. Create calculated column.
Column =
PATHITEM(
SUBSTITUTE(
SUBSTITUTE([Html], ">", "|"),
"</","|"), 2,TEXT)
2. Result:
Best Regards,
Liu Yang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Hi @nirmit27 ,
This is the related document, you can view this content:
https://community.powerbi.com/t5/Desktop/Removing-HTML-Script-from-data-in-Query-Editor/td-p/351995
https://community.powerbi.com/t5/Power-Query/Removing-HTML-tags-complex/m-p/1221727
https://community.powerbi.com/t5/Power-Query/Removing-HTML-tags-and-reordering-text/m-p/1900057
Best Regards,
Liu Yang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
@v-yangliu-msft i have trid HTML.TABLE in M already. These posts show more complicated way of achieving the same result so not sure if these would really be any faster? Again these are older posts probably before the HTML.TABLE function was released.
Any ideas on DAX? I am more keen on doing that to save time in loading up the queries.
@nirmit27 did you tried using Power BI dataflows, just copy the queries from desktop to dataflow and see if it performs better. if you have premium then turn on Enhanced computer engine for dataflow and it will surely be way faster.
✨ Follow us on LinkedIn
Learn about conditional formatting at Microsoft Reactor
My latest blog post The Power of Using Calculation Groups with Inactive Relationships (Part 1) (perytus.com) I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos to whoever helped to solve your problem. It is a token of appreciation!
⚡ Visit us at https://perytus.com, your one-stop-shop for Power BI-related projects/training/consultancy.⚡
Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
@parry2k we can't really move to dataflow option for the complexity involved. I will anyway test it and update here if see any improvements. Thanks for replying.
Any ideas on DAX? I am more keen on doing that to save time in loading up the queries.
Come together to explore latest innovations in code and application development—and gain insights from experts from around the world.
Put your data visualization and design skills to the test! This exciting challenge is happening now through May 31st!
User | Count |
---|---|
363 | |
96 | |
64 | |
54 | |
38 |
User | Count |
---|---|
356 | |
110 | |
75 | |
60 | |
50 |