Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Automate - Using Flows
Unanswered

Update 50,000 Records in CDS using MS Flow

(0) ShareShare
ReportReport
Posted on by 10

Hi,

 

I am trying to update the Contact entity records in CDS using MS flow. I am able to retrieve 512 records by default and update the 512 records successfully. However, I want to update 50000 records using flow. First I tried to retrieve 5,000 records and update this records. When I run flow it does retrieve 5000 records but flow get fails on updating records due to time out. Could you please let me know the reason for same and how can I update 50,000 records using CDS connector in MS flow and how much time it would require to update 50,000 records?

 

Thanks!

  • v-bacao-msft Profile Picture
    on at
    Re: Update 50,000 Records in CDS using MS Flow

     

    Hi @Vikasdugi ,

     

    As described by @yashag2255 , the returned content does indeed exceed the limit and cannot be executed.

     

    You could try to filter records using other properties or use other properties to split these records into multiple parts.

    Then add multiple parallel branches to update these records respectively, relying on Copy action function to quickly create multiple identical branches, like:

    9.PNG

     

    In addition, you could also set Apply to each to provide execution efficiency:

    5.PNG

     

    Best Regards,

  • yashag2255 Profile Picture
    24,442 Super User 2024 Season 1 on at
    Re: Update 50,000 Records in CDS using MS Flow

    Hey @Vikasdugi 

     

    Can you try reducing the number of records and run the flow twice? You already have the filter query and if you are modifying that then the resultant next run will pick the remaining records.

     

    I am guessing that the 50000 hard limit is creating this issue here for the bytes too. You could also collect these in an array and perform any further actions (using any filter queries)

     

    Hope this Helps!

     

    If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

  • Vikas Negi Profile Picture
    10 on at
    Re: Update 50,000 Records in CDS using MS Flow

    Thank you for the reply 

    I have set the top count as 50000 in the list recods and 50000 as threshold of pagination in the settings as below:

    1.png

    2.png

    When I run the flow it fails on list records and gives the below error:

    3.png

    Error: BadRequest. The action 'List_records' has an aggregated page results size of more than '211802208' bytes. This exceeded the maximum size '209715200' bytes allowed.

     

    Could you please help me to understand above error and how can I resolve the same?

     

    Thanks!

  • yashag2255 Profile Picture
    24,442 Super User 2024 Season 1 on at
    Re: Update 50,000 Records in CDS using MS Flow

    Hi @Vikasdugi 

     

    You can set the number of records to be retrieved in the Get Records/ List records action by entering 50000 in the top cound field of the action. ssa.PNG

     

    Currently the CDS connector supports only max of 50000 records to be retrived in flow: https://docs.microsoft.com/en-us/connectors/commondataservice/

     

    Another way of doing this would be: create a workflow and then use XRM toolbox to bulk update those records as Flow might take a lot of time to iterate and update the 50000 records. 

     

    For the timeout issue, you can go to the settings part of the actions and change the time out to P1D (that is a day) or PT24H (24 hours) and see if it works. ssd.PNG

     

     

    Hope this Helps!

     

    If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

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

🌸 Community Spring Festival 2025 Challenge 🌸

WIN Power Platform Community Conference 2025 tickets!

Markus Franz – Community Spotlight

We are honored to recognize Markus Franz as our April 2025 Community…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 146,524 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 65,906 Most Valuable Professional

Leaderboard

Featured topics

Restore a deleted flow