Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics 365 | Integration, Dataverse...
Suggested answer

extracting an #ID from email subject

(1) ShareShare
ReportReport
Posted on by
Hi,
 
I have a flow that I would like to use to update a list item. The ID of the item is contained within the email subject in this form: /#REF1234 Whatever subject follows/ where 1234 is the id. I am looking for the proper function to isolate the ID following #REF from the string this could be any number of digits following #REF. I am unsure one function alone can achieve this, I tried searching a bit and array might seem to be one way to go but i wasn't exactly sure where to start.
 
thanks
  • Dengliang Li Profile Picture
    Microsoft Employee on at
    extracting an #ID from email subject
    Hi,
     
    Has the issue been solved?
    Have there been any updates? Please feel free to ask me if you have any questions!
    If it has been resolved, can you mark the response as an answer?
     
  • Suggested answer
    Dengliang Li Profile Picture
    Microsoft Employee on at
    extracting an #ID from email subject
    Hi,
     
    Is the format of your subject field values fixed?
    For example: #REF1234 space Whatever subject follows
    The #REF always comes first, followed immediately by the ID, then a space followed by the text.
     
    If so, then you can use the following expression.
    slice(outputs('Get_a_row_by_ID')?['body/subject'], 4, indexOf(outputs('Get_a_row_by_ID')?['body/subject'], ' '))
     
    If my answer was helpful, please click Like, and if it solved your problem, please mark it as verified to help other community members find more.
    If you have further questions, please feel free to contact me .
     
    Best Regards,
    Dengliang Li
     

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

Daivat Vartak – Community Spotlight

We are honored to recognize Daivat Vartak as our March 2025 Community…

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Kudos to the February Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 293,202 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 231,923 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156 Moderator

Leaderboard

Product updates

Dynamics 365 release plans