top of page

Mastering Power Automate Expressions from A to Z

Hi, how are you?


It's been a while !


I posted a Linkedin carousel series of posts of some of the functions I find useful in Power Automate. Charlotte Limeslade then asked if I could write up a blog post about it. So here it is.


A-F


Expression

add()


Use Case

Used to add numbers or time values


Example

add(5,10) returns 15.



Expression

base64()


Use Case

Converts text to base64 encoding (commonly used for APIs or email attachments).


Example

base64(Hello) returns SGVsbG8=




Expression

concat()


Use Case

Combines multiple text string into one.


Example

concat ('Hello', ' ','world') returns Hello world.




Expression

div()


Use Case

Divides one number by another.


Example

div(10,2) returns 5.



Expression

endsWith()


Use Case

Checks if a string ends with specific text.


Example

endsWith('Hello World', 'World') returns true.



Expression

formatDateTime()


Use Case

Formats dates and times into a readable string or specific format.


Example

formatDateTime(utcNow(), 'yyyy-MM-dd') returns 2025-06-02.



G-L


Expression

greater()


Use Case

Compares two numbers to see if the first is greater.


Example

greater (10, 5) returns true.



Expression

indexOf()


Use Case

Finds the position of a substring within a string.


Example

indexOf('Hello World', 'World') returns 6.



Expression

join()


Use Case

Combines an array into a single string, separated by a character.


Example

join(['apple', 'banana', pear'], ',') returns apple, banana, pear.



Expression

length()


Use Case

Returns the length of a string, array, or object.


Example

length('Hello') returns 5.



M-R


Expression

max()


Use Case

Returns the maximum value from a list of numbers.


Example

max (5, 10, 20) returns 20.



Expression

not()


Use Case

Negates a condition, returning the opposite (true/false).


Example

not(equals(5,5)) returns false.



Expression

or()


Use Case

Returns true if any condition is true.


Example

or (equals(5,5), equals (3,4)) returns true.



Expression

parseDateTime()


Use Case

Return the timestamp from a string that contains a timestamp.


Example

parseDateTime('10-20/2014 15h', 'en-US', 'MM/dd/yyyy hh\h') // Returns '2014-10-20T15:00:00.0000000'.



Expression

replace()


Use Case

Replaces part of a string with another string.


Example

replace('Hello World', 'World', 'Universe') returns Hello Universe.


S-Z



Expression

substring()


Use Case

Returns part of a string based on start and length.


Example

substring ('Hello',1,3) returns ell.



Expression

trim()


Use Case

Removes spaces from the beginning and end of a string.


Example

trim(' Hello ') returns Hello.



Expression

union()


Use Case

Returns unique values from two arrays.


Example

union(['A', 'B'], ['B', 'C']) returns ['A','B',C'].



Expression

variables()


Use Case

Return the value for a specified variable.


Example

Suppose the current value for a "numItems" variable is 20. This example gets the integer value for this variable:


variables('numItems') would return 20.



Expression

xml()


Use Case

Converts a JSON String to XML format


Example

xml('{"name":"JonDoesFlow"}') returns <name>JonDoesFlow</name>.


Thanks, I hope some of these help.

 
 
 

Recent Posts

See All

Subscribe Form

©2019 by Jon Does Flow. Proudly created with Wix.com

bottom of page