Wednesday, December 10, 2014

RowLimit error says range can only be set to 500 maxinum. But doesn't seem to have any effect in return result.

In SharePoint 2013, based on my experiment/testing: RowLimit setting has no effect on result returned when TotalRowsExactMinimum is set to large nubmer. It has impact when TotalRowsExactMinimum is set to be smaller than total results.

But it seems StartRow is honored for all the cases. Without setting rowlimit. Result is able to return more than 500 results.

When trying to set Keywordquery's RowLimit to large number you will get exception

"RowLimit - The allowed range of values is 0 to 500"

What happens is MaxRowLimit on that application defaults to 500 and that value is passed to the query. RowLimit can't be set to be larger than MaxRowLimit,which is set at search service application level.

The SearchServiceApplication MaxRowLimit can be modified as follows:

PS> $ssa = Get-SPEnterpriseSearchServiceApplication
PS> $ssa.MaxRowLimit = 1000
PS> $ssa.Update()



No comments:

Post a Comment