web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Update row in Excel af...
Power Automate
Answered

Update row in Excel after listed rows have been filtered.

(0) ShareShare
ReportReport
Posted on by 33

Hi,

 

I'm trying to update a row in a test spreadsheet after I have applied a couple of filters to the data.

The spreadsheet is a simple table;

Sheet.jpg

 

 

 

 

1)  I have a manual trigger that just collects some text for comment.

2)  I have a List Rows that is pulling in the data from the spreadsheet.

3)  I then apply 2 filters, one to pull out all the items for Duck and the second to check Have Got = No.

Filters.jpg

 

 

 

 

 

 

 

 

 

 

The filters are working correctly and I end up with Output that contains just the one row of data for Item - Duck, Have Got - No

4) This is where I hit the problem, I now try to update the comment on this filtered data with Update Row.

add row.jpg

 

 

 

 

 

 

 

 

 

 

 

 

This update is ignoring the filters and just updating the first item with Duck in it.

 

How do I get it to just update the filtered information?  I thought that the Apply to each step would have made it just write to the data it retrieved from the filters.

 

Thanks

Jamie.

Categories:
I have the same question (0)
  • efialttes Profile Picture
    14,756 on at

    Hi!

    The update is ignoring the filters since the filters are not the input for the update. 'Update rows' take as the input the excel table you reference inside, there is no way to reference a filtered table.

    In my opinion, you need a key column with unique values. Let's assume you add a new column to your excel table, let's call it 'Index', and provide a unique value per row (1, 2, 3...)

    Now, you should modify slightly your flow, assign as Key Column 'Index' and assign as 'Key value' the following WDL expression:

    item()?['Index']

    Please note you will probably need to delete and add 'Update row' first in order to read the new Column structure

    Hope this helps

  • JamieF4T Profile Picture
    33 on at

    Hi,

     

    Thanks for your reply but it doesn't really do what I was hoping.  This is just a test sheet to prove the process for other things but what I want to be able to do is just amend/add to the data that is returned from a filter array.   

     

    The filters are pulling the data down to a single rows worth of information but it seems nuts that once you have that 'Output' you can't then action changes on just the 'Output' data.

    duck filter.jpg

     

     

     

     

     

     

    I basically just want to add to the "comment": "" listed above.

  • Verified answer
    efialttes Profile Picture
    14,756 on at

    Hi!

     

    If you follow the approach I suggested you would update just the rows from your filtered data. But, if adding an index column cannot be done according to your requirements, I cannot think of any other approach to overcome your challenge.

     

    I mean, the original problem is, you have more than one entry in your Excel table with Key Value 'Duck', so the first one is the one updated. Your current design approach is IMHO wrong.

     

    Happy flowing!

     

     

  • JamieF4T Profile Picture
    33 on at

    I got there in the end using your idea for a record ID.

    Rather than go into lots of detail, I basically added a RecordID to each record using a generated unique string, (based on timestamp).

    When I came to updating the rows I could then run filters and from the filters extract the RecordID and then update the row that corresponded to that RecordID.

    Thanks for you help, pointed me in a different way of thinking which worked a treat 🙂

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 507 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 267 Moderator

#3
abm abm Profile Picture

abm abm 232 Most Valuable Professional

Last 30 days Overall leaderboard