What is the List View Threshold?
All content in SharePoint Online or on-premises SharePoint Server is stored in a SQL Server database and there is a table in that database called AllUserData that contains a row for every item in every list / library in all the site collections that are mapped to a content database.
When SQL Server receives a query that causes it to touch more than 5,000 rows in a table, SQL Server can escalate row locks to a table lock. This is designed to help the query to complete but can also block access to the table by all other users and because the AllUserData table supports so many lists / libraries, a table lock on AllUserData could impact many users.
To prevent this issue Microsoft introduced the List View Threshold in SharePoint 2010 Server to stop SharePoint users from creating escalated table locks.
What happens when a SharePoint container has more than 5000 items
If the ‘container’ (folder, document set or root of the library) contains more than the LVT number of items (i.e. by default more than 5,000 items), the LVT condition will arise. If the List View Threshold condition arises, the view is throttled – i.e. either no items are displayed, or only a subset of the items are displayed.
When the LVT condition is triggered it not only causes throttling of views it also prevents administration tasks such as defining a calculated column or exporting the library as a template.
Microsoft suggest that a document library can contain 30 million files. This is true provided that the files are spread across a large number of folders (or document sets), including folders that are nested within other folders or document sets, and there are less than 5,000 files or folders in the root of the library or in any one folder or document set.
How does DMS handle the List View Threshold
In MacroView DMS 8.5 and earlier when the LVT is triggered, the file list does not display any files and shows a warning message indicating that the LVT has occurred. This continues to be the case with MacroView DMS 8.6 when used with on-premises SharePoint 2013 and 2016,
To view items, you then need to select another view or create a new view that does not trigger the LVT.
In MacroView DMS 8.6 when used with SharePoint Online or on-premises SharePoint 2019 (client side only), a similar approach is used to that used in the SharePoint browser when retrieving items to view in libraries. This means DMS will return the same file list results as seen when selecting the same view in the browser and fewer situations where the LVT is triggered.
Version Support
The updated handling of the List View Threshold is supported in DMS 8.6 when used with the following:
- SharePoint Online
- On-premises SharePoint 2019 (Client Side Only mode)
Known Issues
- Sorting or ordering a view by a non-indexed column when the current folder has more than 5000 items will trigger the LVT in DMS as it does in the browser.