2

I've been struggling with this one fetchxml report for Dynamics CRM online.

The report is using aggregate to detect duplications based on certain fields. So, even though it is an aggregate report, the data set will return a lot of rows. Then I found out that the number of rows returned for aggregate fetchxml is limited to 5000.

I understand that normal fetchxml report will return records more than 5000 but for aggregate report, this doesn't seem to be the case. In the resultset, the 'morerecords' attribute shows as '0' too.

Is there any workaround for this (except to use normal fetchxml to get raw data and handle duplicate check somehow in SSRS because there are charts involved..). Or am I forced to report this to Microsoft so that they can write it off as "By design".

scott_lotus
  • 3,171
  • 22
  • 51
  • 69
Nay Min
  • 85
  • 10

1 Answers1

3

The Fetch Aggregate Limit is actually by default 50,000 rows. It specifies the maximum number of records that can be aggregated. 5,000 is the Query Result Limit which defines the maximum size of a page of data that can be retrieved using the organization service.

On CRM Online you are not allowed to relax these limits, but on OnPremise deployments you can. The deployment service supports an UpdateAdvancedSettingsRequest for this purpose. (More details on MSDN.)

A nice overview of CRM 2011 Timeouts and Limits can be found on TechNet. Most of the information given there also applies to later versions of Dynamics CRM.

Henk van Boeijen
  • 7,357
  • 6
  • 32
  • 42
  • Sorry, my bad. Missed out one zero. I understand that the limit on 50000 rows is the **count**. I also know that the query result limit is 5000, but when you generate a normal (non-aggregate) fetch XML report, the report will go through every page and return the full list. It doesn't seem to be the case for aggregate. Even though my aggregate **total counts** doesn't exceed 50000, if the result rows exceed 5000, the data will be cut off. I noticed that no paging information is returned either.. Guess I will have to ask the user to compromise on the charts. – Nay Min Jan 15 '16 at 04:06