Cheat Sheets/Power Automate/length
Power Automate (WDL) function

lengthPower Automate (WDL) function reference

Count characters (or array items).

Syntax

wdl
length(collection)

Examples

wdl
length('PowerStack')
10
wdl
greater(length(split(item()?['Tags'], ',')), 1)
true when more than one tag is present
wdl
equals(length(triggerBody()?['Attachments']), 0)
true / false

Also used under "Arrays & collections": count items in an array.

wdl
length(variables('rows'))
A number

Common mistakes & gotchas

Related Workflow Definition Language functions

From Strings

Used in these tutorials

← Back to the Power Automate (WDL) cheat sheet