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 / Delete item with speci...
Power Automate
Unanswered

Delete item with specific word from last year

(0) ShareShare
ReportReport
Posted on by 26

Hi,
I really enjoy finding and using solutions here, but unfortunately not every answer fits. 

Now i have created the following flow through a previous solution, there it was still about deleting a calendar, which also worked great.

PA.png

Now i have a List and it is possible to delete only the entry "Avocado" from the year 2022 with the same flow?

What if I have more than one list?

SharePoint.JPG

I only found and try the "switch" function, which I think is very unflexible. 

 

Thanks for your help! ✌️

Categories:
I have the same question (0)
  • Verified answer
    rzaneti Profile Picture
    4,241 Super User 2025 Season 2 on at

    Hi @AnG96 ,

     

    For this answer, I used list structure very similar to yours:

    rzaneti_0-1689092031556.png

     

    In Power Automate, you use 'Get Items' action (as you already did) to return the records form a SharePoint List. In the filter query, you may specify what do you want to return from the list, which in our case is the records with 'Avocado' in title and with 'Date' column from 2022 (it means, lower or equal to December 31st 2022 AND greater or equal to January 1st 2022). Make sure to add the 'and' operator (highlighted in green) to apply all filter expressions (highlighted in yellow) to your action:

     

    rzaneti_2-1689092549288.png

     

    Then you just need to add an 'Apply to each' loop and insert your delete action inside the loop block:

    rzaneti_3-1689092840788.png

     

    Output:

    After run the flow, the 'Get items' will return only one item (title Avocado, with date from 2022) and delete it from the List:

    rzaneti_4-1689092908732.png

    rzaneti_5-1689092921930.png

     

     

    Let me know if it works for you or if you need any additional help!

     

    -------------------------------------------------------------------------
    If this is the answer for your question, please mark the post as Solved.
    If this answer helps you in any way, please give it a like.

     

  • AnG96 Profile Picture
    26 on at

    Hi @rzaneti 
    the solution works great!
    I also read out the last year and now I don't have to adjust the time every year.

    Year.JPG

     

    formatDateTime(utcNow(),'yyyy')

    sub(int(variables('varYear')),1)

    I'm sure the solution is also simple, but it's ok for me to learn if it works. 😀

    Thanks a lot!

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 522 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 406 Moderator

#3
abm abm Profile Picture

abm abm 245 Most Valuable Professional

Last 30 days Overall leaderboard