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

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics CRM (Archived)

Advanced Find count over 5000

(0) ShareShare
ReportReport
Posted on by

Hi,

I am struggled with a performance problem regarding the count of the records in the advanced find window using the Online version of the CRM 2016.

I have managed to get the fetchXml data of the query and, when I press my custom "record count" button, I do a fetch request through xrmservicetoolkit and then count the records retrieved.

As you can imagine the time to retrieve the data is very long, lets say that for 250K records it require 1:50 minutes.

XrmServiceToolkit.Soap.Fetch(fetchString, true, function(result){
     console.log("this will appear when the fetch is completed");
     var webResourceData = encodeURI("count=" + result.length);
     console.log("count: " + result.length);      
     Xrm.Utility.openWebResource("goal_advancedfindcountresult",webResourceData,200, 100);
     return;
});

I have tried with the aggregate but is not possible to count more than 5000 records.

Any in how to avoid fetching all the data and only get the count?

Thanks in advance

Andrea

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    Alagunellaikumar Profile Picture
    6,212 on at

    Hi

    In deployment properties table's "AggregateQueryRecordLimit" column you can change the value for  fetch xml aggregate

  • Suggested answer
    Alagunellaikumar Profile Picture
    6,212 on at

    Also to confirm it is not 5000 record, maximum 50,000 by default

  • Community Member Profile Picture
    on at

    Hi Alagu,

    thanks for the reply. I've forgot to mention that I am workin on an Online Environment, so what you proposed is not applicable for me.

    I am going to update the post for future replies

  • Suggested answer
    Alagunellaikumar Profile Picture
    6,212 on at

    For CRM online there is no possible to way, only way is retrieve another set of record. PLease refer below link

    lakshmanindian.wordpress.com/.../retrieving-more-than-50-records-using-odata-in-crm-2011

    www.xrmlabs.com/.../How-to-retrieve-more-than-50-records-through-OData-in-CRM-2011

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics CRM (Archived)

#1
SA-08121319-0 Profile Picture

SA-08121319-0 4

#1
Calum MacFarlane Profile Picture

Calum MacFarlane 4

#3
Alex Fun Wei Jie Profile Picture

Alex Fun Wei Jie 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans