Forum Discussion
Venkat Konjeti
Sep 27, 2019Copper Contributor
SharePoint Search REST API returns inconsistent Total Rows Count
Hello Everyone, We are a building a custom web part with pagination feature. To implement feature we are getting Total rows count and showing possible number of pages. While implementing we a...
Mikael Svenson
Nov 20, 2019Iron Contributor
Venkat Konjeti Hi, this is by design when you use duplicate trimming, as trimming the full result set is time consuming, so it will re-calculate as you are paging.
My personal opinion is that you should turn off duplicate trimming as it's too coarse (https://www.techmikael.com/2013/12/duplicate-trimming-in-sharepoint-2013.html). Append &trimduplicates=false and you should be good to go.
As a side not, if you get very many results, then the exact count might also be off, due to the query returning within a timeout interval.