Skip to main content

Notifications

Power Apps - Microsoft Dataverse
Suggested answer

Converting accented characters

(0) ShareShare
ReportReport
Posted on by 2
So, correct me if I'm wrong, but I couldn't find any way to convert accented characters other than humongous pieces of code and formulas that 90% of the time just don't work?
In MS SQL I can use TRANSLATE. But in Dataverse, everything that I find is to use Power Automate, or use substitute (which never works).

Thanks for the help.
Categories:
  • Suggested answer
    CU20121206-0 Profile Picture
    CU20121206-0 2 on at
    Converting accented characters
    @Mark Nanneman

    I ended up finding this little solution here:
    Solved: Re: Convert names to email address - Power Platform Community

    But thanks for the tips, man.
  • Suggested answer
    Mark Nanneman Profile Picture
    Mark Nanneman 836 on at
    Converting accented characters
    It is annoying that Power Automate doesn't have a function to convert strings to HTML friendly text.

    In Power Automate I liked to use Fetch XML queries (as opposed to OData filters) to filter Dataverse rows that might have a single quote ( ' ) in the name.  It will unfortunately still break if there are certain other reserved characters (like say an ampersand or a double quote).  For those I use a couple replace actions to convert them to HTML entity equivalents.

    Basically a formual like this works 99% of the time:
    replace(
        replace(
          replace(
            replace(triggerBody()?['text'], '&', '&'),
            '<', '&lt;'
          ),
          '>', '&gt;'
        ),
        '"', '&quot;'
    )
     
     
    You can create your Fetch XML search by opening the table in question in a Model Driven App and clicking "Edit filters"

    Then write something like this (I put a placeholder in {{ just so it's easier to find in the final XML).
     
    Click "Download FetchXML and open it in a notepad, then copy and paste it in your flow.
     
    Replace the placeholder variable with a dynamic reference.  Here I just drop in a compose action that does the replace functions for ampersands etc.
    Example, searching for A&W
     
    Hope that helps!

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Kickstarter Events…

Register for Microsoft Kickstarter Events…

Tuesday Tip #12 Start your Super User…

Welcome to a brand new series, Tuesday Tips…

Tuesday Tip #13 Writing Effective Answers…

Welcome to a brand new series, Tuesday Tips…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 144,940

#2
RandyHayes Profile Picture

RandyHayes 76,287

#3
Pstork1 Profile Picture

Pstork1 64,523

Leaderboard

Featured topics