Saturday, May 5, 2012

List Settings Error 0x80070024

Recently we faced a problem accessing "List Settings". The error said "The attempted operation is prohibited because it exceeds the list view threshold enforced by the administrator. 0x80070024." The List Settings page was working fine in the other site collections.

We created one custom list with one item. The list has the same issue even though it has single item.

We found an entry in ULS Logs saying "big list, slow query operation" The log has mentioned the List GUID which is being queried. I wrote a Powershell to find the list. The list is hidden "Workflows" document library. I tried the document library URL in browser, it returned me "404 Not found". One of my colleague used the list guid with _layouts/listedit.aspx(application page List Settings refer) and it did show us the Library settings. We verified the library settings but it did not helped.

I wrote a PowerShell to find the number of items in the list and it returned 0. So there are no items but still it is causing the issue. We were clueless about the behavior. I wrote the below PowerShell script, executed it, and there were no errors on hitting the "List Settings".

$web=Get-SPWeb [webUrl]  #remove the square bracckets here
$list=$web.Lists["Workflows"]  #Keep the square brackets in this line.
$list.EnableThrottling=$false
$list.Update()

For the time being, we used this solution. I am investigating the cause for the issue. The "Workflows" document library is used to store the site level workflows. The library is created by SharePoint Designer (SPD) on first ever SPD workflow creation in the site.

Visit again, for the updates!
[Update 05/08/2012: I found that the "Workflows" library reports -1 in ItemCount. As such, no list or library should report ItemCount as a negative number. As mentioned in this post, Microsoft has accepted that MOSS 2007 has the issue of negative ItemCount. The site, we are referring to, is a migrated site. So the library was reporting negative ItemCount. Negative item count is a cause for failure of indexing operation. If indexing fails, queries perform slow. It was causing the throttle issue even though the "Workflows" library is empty.

Resolution: If the "Workflows" library is empty, delete it. SharePoint Designer will recreate the library on SPD workflow creation. If the library is not empty, then there will be no issue as ItemCount will always report positive number.

The issue may occur only in migrated sites hoping that Microsoft has taken care of the issue in SharePoint 2010.]
Post a Comment