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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Automate
Answered

Get Items

(1) ShareShare
ReportReport
Posted on by 113

I have a flow 'When an item is created' with various steps including updating the item just created and oteh calculations, at one point within the flow I have a 'Get items' where I am looking to retrieve a specific value in a column from the second last record retrieved via teh fileter query which would include the one currently created e.g.

Capture.JPG

Any thoughts on how I can achive this withi the Get Items?

Thanks

Categories:
I have the same question (0)
  • trice602 Profile Picture
    15,905 Super User 2026 Season 1 on at

    Hi @E9Mate ,

     

    Have you considered using Get Items first with a Top Count = 1 and retrieve the desired record first?  Then, add your new item, etc.  This is the easy way.

     

     

  • E9Mate Profile Picture
    113 on at

    Hi @trice602 , 

    I don't think that would be the best approach or how to achieve it that way.

    The interface is set up for the user to enter the information on a SharePoint list, based on what information is entered and saved.

     

    Basically various user work on a specific record that is entered on SharePoint list (ID85 in the example) when all users have finished the record will be closed with one specific column containing an outcome WOK = Level 1.

    When a new item is created (which could be month later) the 'Get items' is triggered on the back of 'When an item is created' and would filter all entries based on the filter query rule which would include also the latest entry ID90.

    I then need to update the latest entry (ID90 of the When an item is created) with the information contained in the outcome of the record entered months behind. 

    In the example below ID90 is the latest record created and retreived from the 'Get items', the next step in the flow would be update ID90 with the information contained in ID85, and update it with the value contained in WOK which is Level 1

    Basically this would be the second last item retrieved.

    Capture.JPG

    Hope this makes more sense to what I am trying to achieve.

    Thanks

     

  • Chriddle Profile Picture
    8,525 Super User 2026 Season 1 on at

    Set Get Items to sort by ID in descending order, only get two items, and in the next connector pick up the last one.

  • E9Mate Profile Picture
    113 on at

    Hi @Chriddle.

    Thanks for the hint, I have a compose action and used the 

    last(outputs('Get_items')?['body/value'])

     

    Screenshot 2023-11-02 091543.png

     

    I need now to update the item, but I am stuck on how to retrieve the value in the column from the Compose action.

    I can see the correct information I need to get the value 'Level 1' and update the item with this

    Screenshot 2023-11-02 091740.png

    Thanks,

  • Verified answer
    Chriddle Profile Picture
    8,525 Super User 2026 Season 1 on at

    Something like this:

    outputs('Compose')['LevelTriggered']['Value']
  • E9Mate Profile Picture
    113 on at

    @Chriddle Thanks for your help with this matter.

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Leaderboard > Power Automate

#1
David_MA Profile Picture

David_MA 112 Super User 2026 Season 1

#2
Haque Profile Picture

Haque 52

#3
Ellis Karim Profile Picture

Ellis Karim 51 Super User 2026 Season 1

Last 30 days Overall leaderboard