Skip to main content

Notifications

Power Automate - General Discussion
Unanswered

Get Items Returned Duplicates

(2) ShareShare
ReportReport
Posted on by 12

This is a pretty strange one that I've not been able to replicate.

 

My Flow is pretty big and does quite a lot.  Essentially it gets items from a SharePoint list, does some calculations, creates items in another list, gets those items and creates a CSV file.

 

In Get Items step before creating the CSV I have a run that has returned 199 items, but there was only 197 items in the list.  On checking the Outputs from the Get Items step I found 2 duplicate items (i.e. the same internal ID). 

 

I have run the flow again and it didn't happen, but the fact that it has happened is causing some concern and I'm trying to find some kind of explanation as to why it happened.

 

Has anyone had anything similar or any suggestions as to why it might have occurred? 

 

Thanks in advance...

  • CindyZ Profile Picture
    CindyZ on at
    Re: Get Items Returned Duplicates

    @Dexrend Thanks so much for jumping in here with this input!  Anxious to try this!  

  • Dexrend Profile Picture
    Dexrend 18 on at
    Re: Get Items Returned Duplicates

    I had the Same issues. I couldn't get it to stop. if i compose the items in a Union function it got rid of them. 

    union(body('Get_items'),body('Get_items'))
  • CindyZ Profile Picture
    CindyZ on at
    Re: Get Items Returned Duplicates

    Facing this issue now.  It is creating duplicates, triplicates, etc., when there is only 1 record. It is not consistent in the duplications.  All the ID numbers are identical when it replicates a record so I know it is looking at only 1 record and should be returning only 1 record; not  2 or 3. 

  • martmoldau Profile Picture
    martmoldau 2 on at
    Re: Get Items Returned Duplicates

    Seems as Get Items bug for me too. Removing orderby value is a workaround which fixed it for me.

  • ronald_caro Profile Picture
    ronald_caro 27 on at
    Re: Get Items Returned Duplicates

    Hi @panchomx good day! Are you able to share your expression used in Compose for "union()" so that we can see and pattern it to our side?  Thanks!

  • PR001 Profile Picture
    PR001 28 on at
    Re: Get Items Returned Duplicates

    I'm also getting the same issue with the outputs of the Get Items is returning duplicates for certain rows.  Clearly appears to be a bug.

  • Dexrend Profile Picture
    Dexrend 18 on at
    Re: Get Items Returned Duplicates

    I also have this issue. I have 20 items in the list and it returns 40. Is anyone working on this issue?

  • ShehanMP Profile Picture
    ShehanMP 74 on at
    Re: Get Items Returned Duplicates

    I'm facing the exact same issue. There are no duplicates in the SharePoint list items but when I run the flow, in Get Items Output it clearly shows some duplicate items.

    Can we write this to Microsoft?

  • AshleyGambino Profile Picture
    AshleyGambino 2 on at
    Re: Get Items Returned Duplicates

    I know it's been over a year since this was originally posted, but I had the same exact issue and was finally able to figure out what was happening. Again, the issue was that I was creating an HTML table with a filtered Get Items action, but the HTML table was only returning the first item in every single row. Weiiiiird right?

     

    In case anyone else comes across this post and needs the solution:

    In the Create HTML Table action, when you are selecting dynamic content for the Value column, make sure you are selecting the value from the "Get Items" section, NOT the "When an item is created or modified" section (or whatever your initial trigger was).

     

    In the screenshots you can see that I searched for "link" in the dynamic content pop-up window and there are two values for "Link to item": one is in the Get Items section, and one is in the When an item is created or modified section. Again, pick the one in the Get Items section.

     

    2023-02-23_12-49-15.png

    2023-02-23_12-49-51.png

  • panchomx Profile Picture
    panchomx 6 on at
    Re: Get Items Returned Duplicates

    What I did to avoid duplicated records on Get Items is to add 2 additional steps:

    1) Create an array variable using the Get Items output as the input

    2) Use a compose using Union expresion

     

    You can now use the compose output having unique records (avoiding duplicated SP internal IDs)

     

    panchomx_0-1659023558398.png

     

    Hope this helps you!

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

Microsoft Kickstarter Events…

Register for Microsoft Kickstarter Events…

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Announcing Forum Attachment Improvements!

We're excited to announce that attachments for replies in forums and improved…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 145,580

#2
RandyHayes Profile Picture

RandyHayes 76,287

#3
Pstork1 Profile Picture

Pstork1 64,909

Leaderboard