Microsoft.SharePoint.SPQueryThrottledException: List View Treshold da modificare

Microsoft.SharePoint.SPQueryThrottledException: L'operazione
tentata non è consentita poiché supera la soglia della visualizzazione elenco
imposta dall'amministratore. --->
System.Runtime.InteropServices.COMException (0x80070024): L'operazione tentata
non è consentita poiché supera la soglia della visualizzazione elenco imposta
dall'amministratore.

at Microsoft.SharePoint.Library.SPRequestInternalClass.GetListItemDataWithCallback2(IListItemSqlClient
pSqlClient, String bstrUrl, String bstrListName, String bstrViewName, String
bstrViewXml, SAFEARRAYFLAGS fSafeArrayFlags, ISP2DSafeArrayWriter pSACallback,
ISPDataCallback pPagingCallback, ISPDataCallback pPagingPrevCallback,
ISPDataCallback pFilterLinkCallback, ISPDataCallback pSchemaCallback,
ISPDataCallback pRowCountCallback, Boolean& pbMaximalView)

 at Microsoft.SharePoint.Library.SPRequest.GetListItemDataWithCallback2(IListItemSqlClient
pSqlClient, String bstrUrl, String bstrListName, String bstrViewName, String
bstrViewXml, SAFEARRAYFLAGS fSafeArrayFlags, ISP2DSafeArrayWriter pSACallback,
ISPDataCallback pPagingCallback, ISPDataCallback pPagingPrevCallback,
ISPDataCallback pFilterLinkCallback, ISPDataCallback pSchemaCallback,
ISPDataCallback pRowCountCallback, Boolean& pbMaximalView)

   ---
End of inner exception stack trace ---
at Microsoft.SharePoint.SPGlobal.HandleThrottleException(COMException comEx)
at Microsoft.SharePoint.Library.SPRequest.GetListItemDataWithCallback2(IListItemSqlClient
pSqlClient, String bstrUrl, String bstrListName, String bstrViewName, String
bstrViewXml, SAFEARRAYFLAGS fSafeArrayFlags, ISP2DSafeArrayWriter pSACallback,
ISPDataCallback pPagingCallback, ISPDataCallback pPagingPrevCallback,
ISPDataCallback pFilterLinkCallback, ISPDataCallback pSchemaCallback,
ISPDataCallback pRowCountCallback, Boolean& pbMaximalView)
at Microsoft.SharePoint.SPListItemCollection.EnsureListItemsData()
at Microsoft.SharePoint.SPListItemCollection.GetEnumerator()
at ASP._layouts_documenticorrelatisearch_aspx.findDiscussion(SPList lst, String
discussion)  
at ASP._layouts_documenticorrelatisearch_aspx.Page_Load()

Questo errore è generato dalla configurazione standard di SharePoint che imposta, by default, il List View Treshold (LVT) a 5000 elementi. E' un'impostazione che può essere modificata ma fate attenzione a non buttare lì numeri a caso, perché ognuno di questi ha un impatto sulle performance della vostra farm SharePoint.

Modificare il LVT è molto semplice e potete trovare un'ottima guida sulle varie impostazioni di una Web Application qui: https://blogs.msdn.com/b/dinaayoub/archive/2010/04/22/sharepoint-2010-how-to-change-the-list-view-threshold.aspx