Hello Power Automate Community,
First time using Excel connector. I'm going round in circles and would like some help please.
My business case is:
I have an Excel table with a number of rows. One column is "Status Reason".
I want to be able to get all rows that have the "Status Reason" which equals "Send Approval Email".
I then want to do several things on each row, such as update it and send an approval email.
I've used the "Apply to each" action, but I only appear to be able to update the first record and it ignores all the others.
Here is my flow. I've deleted all the other actions. What's my next step please?
Any help would be much appreciated.
Thanks very much,
Garry
@GarryPope excellent friend. Please mark the post as solved to guide others 😉
For anyone who is interested, I've figured this out. I was being an idiot.
On the Excel Online (Business) action "Get a row" there are two fields: "Key Column" and "Key Value".
I was using a column and value which wasn't unique.
I should have put another column, such as "IDNumber", and make sure every value is unique value.
Issue solved.
Hello @ChristianAbata,
Once again, thanks so much for the reply.
My filter does exactly what you mentioned. I have three rows, two rows have the StatusReason of Send Approval Email.
The Flow runs twice as it finds StatusReason of Send Approval Email in two rows, but runs through the first row twice, rather than moving onto the second row. Odd.
Thanks very much,
Garry
@GarryPope could be because you are filtering your data with the value Send Approval Email, so when you do an apply to each is showing you just the values filtered with Send Approval Email value
Hello @ChristianAbata,
Thanks so much for replying. I added the apply to each, but getting some strange behaviour.
Here is my Flow:
For testing purposes my Excel table has 3 rows.
I've made two rows have the StatusReason value of Send Approval Email, and the third row something different.
The Flow runs, and only runs through two records, which is correct due to the Filter Query, as above.
But, when I look at the output of the two Apply to each records, it only shows the top row of the Excel file, so it's looped through the first row twice.
First apply to each:
Second apply to each:
Any idea why the apply to each is reading the same record twice?
Any help would be much appreciated. Thanks very much,
Garry