In Power Automate, the “substring” function is used to extract a specific portion of a string based on starting and ending points. It is useful when you need to manipulate or extract data from strings in your power automate flow.
Syntax for substring() function in Power Automate:
substring(string, startIndex, length)
String: The string from which you want to extract the substring.
StartIndex: The zero-based index position in the string where the extraction should begin.
Length: The number of characters to include in the returned substring.
substring(variables('Atul Yadav'), 0, 5)
If you want to extract the first five characters from a string stored in a variable text, you will have to use the expression substring(variables(‘text’), 0, 5). This will return the first five characters of the string in the text.
Need help? Connect Atul
- Key Vault parameters in Dynamics 365 F&O - July 29, 2025
- User-based authentication RSAT - July 22, 2025
- Boost First-Load Performance in Dynamics 365 F&O with IIS Preload - July 15, 2025
Thank you, Atul Yadav, for this insightful and well-explained blog on using the substring function in Power Automate!
Great work!