Loading...

Operation prohibited because it exceeds the list view threshold

Title

Operation prohibited because it exceeds the list view threshold

Description

Operation prohibited because it exceeds the list view threshold

Please wait...
ListView web part displays error: “The attempted operation is prohibited because it exceeds the list view threshold enforced by the administrator.” ListView web part aggregates data from one SharePoint List.

Cause

 Based on our research it turns out that the exception that is being returned is by design. The threshold feature is actually doing what it is supposed to. Here is an excerpt from an article from Microsoft called Query Throttling and Indexing.
http://msdn.microsoft.com/en-us/library/ff798465.aspx

The list view threshold does not apply simply to the number of results returned by your query. Instead, it restricts the numbers of database rows that can be accessed in order to complete execution of the query at the row level in the content database. For example, suppose you are working with a list that contains 10,000 items. If you were to build a query that returns the first 100 items sorted by the ID field, the query would execute without issue because the ID column is always indexed. However, if you were to build a query that returns the first 100 items sorted by a non-indexed Title field, the query would have to scan all 10,000 rows in the content database in order to determine the sort order by title before returning the first 100 items. Because of this, the query would be throttled, and rightly so—this is a resource-intensive operation.

In this case, you could avoid the issue by indexing the Title field. This would enable SharePoint to determine the top 100 items sorted by title from the index without scanning all 10,000 list items in the database.

Resolution

In this case, you could avoid the issue by indexing the Title field. This would enable SharePoint to determine the top 100 items sorted by title from the index without scanning all 10,000 list items in the database.

Defect ID

 Based on our research it turns out that the exception that is being returned is by design. The threshold feature is actually doing what it is supposed to. Here is an excerpt from an article from Microsoft called Query Throttling and Indexing.
http://msdn.microsoft.com/en-us/library/ff798465.aspx

The list view threshold does not apply simply to the number of results returned by your query. Instead, it restricts the numbers of database rows that can be accessed in order to complete execution of the query at the row level in the content database. For example, suppose you are working with a list that contains 10,000 items. If you were to build a query that returns the first 100 items sorted by the ID field, the query would execute without issue because the ID column is always indexed. However, if you were to build a query that returns the first 100 items sorted by a non-indexed Title field, the query would have to scan all 10,000 rows in the content database in order to determine the sort order by title before returning the first 100 items. Because of this, the query would be throttled, and rightly so—this is a resource-intensive operation.

In this case, you could avoid the issue by indexing the Title field. This would enable SharePoint to determine the top 100 items sorted by title from the index without scanning all 10,000 list items in the database.

Leave a Reply