Is there any direct way to retrieve the number of rows that are returned from a 'get rows' action?
This is what I've tried but it results in the error beneath. Ideally, I'd like to avoid looping around the results and incrementing a variable. Thanks!
InvalidTemplate. Unable to process template language expressions in action 'Compose' inputs at line '1' and column '1590': 'The template language expression 'length(outputs('GetRows').value)' cannot be evaluated because property 'value' doesn't exist, available properties are 'statusCode, headers, body'. Please see https://aka.ms/logicexpressions for usage details.'.
I tried your method but I only got 5,000 records. My table definitely has more than that. Is this the limitation of Power Automate?
Thanks for posting this @EdHansberry. Things have changed so I'm sure this will be a great help to others.
I do not think these instructions work anymore. Here is what I did in 2020, 3 years after this was posted, where I am sure things have changed a bit in the product.
that is it. It counts records returning an integer. A fuller view of the flow:
By any chance can we get current item number/Row number during each iteration ..?
if yes how can we get during error handling i would like to get each line/row number where/when it throws error.
you reply would be really appreciated
Thanks! Flow has made getting the length of an array as simple as resetting a lightbulb! https://www.youtube.com/watch?v=1BB6wj6RyKo
Very happy to help.
😂
Yes you were correct.
Thank you very much.
I really must invite you one day to support us in our company. 😂
we use a lot Flow and O365 environment and i'm not a trained It guy
The name of the ACTION is Get Rows Invoices (hover over the top of value under dynamic content and it should give you the name it is using). I suspect it is Get_rows_Invoices. Replace Get_rows with this as in "@length(body('Get_rows_Invoices')?['value'])"
I'm getting this error:
The template validation failed: 'The action(s) 'Get_rows' referenced by 'inputs' in action 'Compose' are not defined in the template.'.
"@length(body('Get_rows')?['value'])" in the compose input. length will give the count of rows.
rpersad
16
David_MA
10
Super User 2025 Season 1
Michael E. Gernaey
8
Super User 2025 Season 1