none
SP 2010 Document Library Column "Show Filter Choices" is not appearing

    Question

  • Environment:  SharePoint Server 2010 Enterprise - SP1 and June 2011 CU applied;  Document library with >75,000 items.   Upgraded UI from the 2007 version to the current user interface.

    When the MOSS2010 environment was still using the 2007 User Interface, a filter on a column that would return a large volume of results would display the "Show Filter Choices" dialogue in the UI.   This worked great!

    However, after upgrading to the 2010 UI, when attempting to filter a column that returns more than 10,000 results, the browser hangs (IE 9, but also tested with IE8 and IE7).    The "Show Filter Choices" dialogue never appears and the browser hangs and eats workstation resources.

    I have also replicated in a Test environment on a document library with <10,000 items and again the "Show Filter Choices" does not appear when attempting to filter a column that would return a large number of results.   However, after a long delay, the filter choices finally appeared.

    Is there a method to have the "Show Filter Choices" appear on a column filter?    Without this, my users are having to resort to search results instead of being able to filter and this is not acceptable long-term.

    Thanks,

    Saturday, July 16, 2011 8:15 PM

All replies

  • Further to the above, the webpart page also had AJAX options turned on (Enable Asynch Update and automatic refresh).   When I turn off the AJAX features, the column filter now shows the "Show Filter Choices"!

    So, there's a partial solution to this, but it means having to forego the AJAX functionality.    Is there a way to get AJAX and Show Filter Choices working?

    On a related note, although Show Filter Choices is appearing, when selecting it on columns that return many values, an error is displayed saying "Unable to display this Web Part. To troubleshoot the problem, open this Web page in a Microsoft Sharepoint Foundation-compatible HTML editor such as Microsoft SharePoint Designer.  If the problem persists, contact your Web server administrator."  along with a Correlation ID.    The log entry for the correlation id indicates that a Stack Overflow Exception occurred:

    07/16/2011 18:15:01.94 	w3wp.exe (0x16AC)            	0x18F0	SharePoint Foundation     	Web Parts           	89a1	High  	Error while executing web part: System.StackOverflowException: Operation caused a stack overflow.   at Microsoft.Xslt.NativeMethod.CheckForSufficientStack()   at SyncToNavigator(XPathNavigator , XPathNavigator )   at <xsl:apply-templates mode="printTableCellEcbAllowed">(XmlQueryRuntime , XPathNavigator , XPathNavigator )   at <xsl:template match="Row" mode="Item">(XmlQueryRuntime , XPathNavigator , IList`1 , IList`1 , Double , Double )   at <xsl:template match="View" mode="RenderView">(XmlQueryRuntime , XPathNavigator )   at <xsl:template match="View" mode="full">(XmlQueryRuntime , XPathNavigator , String )   at <xsl:template match="View" name="View_Default_RootTemplate" mode="RootTemplate">(XmlQueryRuntime , XPathNavigator , String )   at <xsl:template match="/">(XmlQueryR...	1d8ec968-87fb-4bb0-b40f-cc1bea214a77
    07/16/2011 18:15:01.94*	w3wp.exe (0x16AC)            	0x18F0	SharePoint Foundation     	Web Parts           	89a1	High  	...untime )   at Root(XmlQueryRuntime )   at System.Xml.Xsl.XmlILCommand.Execute(Object defaultDocument, XmlResolver dataSources, XsltArgumentList argumentList, XmlWriter writer, Boolean closeWriter)   at System.Xml.Xsl.XmlILCommand.Execute(IXPathNavigable contextDocument, XmlResolver dataSources, XsltArgumentList argumentList, XmlWriter results)   at System.Xml.Xsl.XslCompiledTransform.Transform(IXPathNavigable input, XsltArgumentList arguments, XmlWriter results)   at Microsoft.SharePoint.WebPartPages.DataFormWebPart.ExecuteTransform(XslCompiledTransform xslCompiledTransform, XsltArgumentList xmlArguments, Boolean bDeferExecuteTransform)   at Microsoft.SharePoint.WebPartPages.DataFormWebPart.PrepareAndPerformTransform(Boolean bDeferExecuteTransform)	1d8ec968-87fb-4bb0-b40f-cc1bea214a77

    I will create a separate thread for this error but listing it here as it's related.

    Sunday, July 17, 2011 2:47 PM
  • Hi Brent,

    Based on my research, SharePoint shows the "Show Filter Choices" in the following scenario:

    1. SharePoint renders all items from the current column in a IFrame
    2. The Items are generated as Option in HTML
      <SELECT id=diidFilterLinkTitle onchange='FilterField("{972901A4-C6E3-453E-89A3-B5B473296647}","LinkTitle",this.options[this.selectedIndex].value, this.selectedIndex);' title="Filter by Title"><OPTION selected value="">(All)</OPTION><OPTION value=1>1</OPTION>... ...</SELECT>
      
    3. When the options are larger than 500, the "Show Filter Choices" will be added

    According to the analyzing, if each item has a lot of text(e.g. 20 byte per item), and there have more than 75,000 items, then the IFrame will be larger than  1.4 MB(20*75000\1024\1024). This will cause the network and the web browser performance issue.

    The solutions to fix the issue are that:

    1. Make sure the network bandwidth are good enough
    2. Create a view to filter the items instead of filtering the column on-demand(it means filtering the column by clicking the column title)

    Thanks,
    Jinchun Chen


    Jinchun Chen
    Forum Support
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact tnmff AT microsoft.com(Please replace AT with @)
    Monday, July 18, 2011 7:25 AM
    Moderator
  • Thanks for the response Jinchun.

    However, you have not addressed why this functionality works absolutely fine when using the 2007 UI but when the visual upgrade was performed, the problem occurs (see my 2nd post within this thread).    It's not a matter of bandwidth as this worked previously and this is not a performance issue.

    The issue is that functionlity that worked prior to the visual upgrade no longer works -- and the user experience is quite poor as they receive the nasty error message in my post.

    Also, the show filter choices only works when the AJAX options are not set.    Is there a way to enable both?

    Thanks.


    Monday, July 18, 2011 10:37 AM
  • Hi Brent,
     
    Actually, SharePoint calls JavaScript functions from core.js to render the filter options. Based on my research, SharePoint 2007 and SharePoint 2010 use almost same functions to render the filter options.
    I compared the performance of rendering the filter options between SharePoint 2007 and SharePoint 2010 in this way:
    1. Created a list with a same name in SharePoint 2007 and SharePoint 2010
    2. Added 100,000 items to each on the 2 lists
    3. Ad-hoc filter the column(clicking the column title)

    Here is the result:
    SharePoint 2007: 12 seconds (From the column was clicked to the "Show Filter Choices" was shown)
    SharePoint 2010: 10 seconds

    In this case, you can use the Fiddler to check if the server responses the data correctly.

    For your another question - AJAX, with AJAX enabled, the web browser will use JavaScript to request the data async. The script is long running. You may see "Stop running this script?A script on this page is causing your web browser to run slowly. If it continues to run, your computer might become unresponsive.".

    To fix the issue, I would suggest you using View to filter the data instead of Ad-hoc filtering.
     
    Just let you know, the "diidFilter" might be null. When "diidFilter" is null, SharePoint 2007 shows the "Show Filter Choices" anyway.
    However, in SharePoint 2010, when the "diidFilter" is null, the following alert message will be shown in web browser while filtering the column:
    Cannot show the value of the filter. The filed may not be filterable, or the number of items returned exceeds the list view threshold enforced by the administrator.
    In addition, in SharePoint 2010, when the "diidFilter" is null and AJAX is enabled, the message "This column type cannot be filtered" will be shown instead of "Show Filter Choices".
     
    In SharePoint 2010, we have a new setting to improve the list view's performance, it is "List View threshold". In order to change the "List View Threshold" in SharePoint 2010, please see:
    http://sharepointnomad.wordpress.com/2011/05/04/solving-the-attempted-operation-is-prohibited-because-it-exceeds-the-list-view-threshold-error/
     
    If you have any more questions, please feel free to ask.
     
    Thanks,
    Jinchun Chen


    Jinchun Chen
    Forum Support
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact tnmff AT microsoft.com(Please replace AT with @)
    Tuesday, July 19, 2011 9:14 AM
    Moderator
  • Hi Jinchun,

    Thanks for your reply.    I have performed more testing on this function and have been able to determine:

    1. Show filter choices works absolutely fine even on large lists when creating a new standard view.
    2. However, if the view is modified using Sharepoint Designer (e.g. conditional formatting to hide content based on valud of another column, OR customizing the xsl), View Filter Choices ceases to function on large lists and must be filtered down significantly before it will function -- the "unable to display webpart" error appears.
    3. With the SPD2010 modification, the "unable to display webpart" error appears very inconsistently....sometimes when using a filter returning only 600 values, the error will occur but at other times, it will function when the number of values returned is in the thousands.
    4. On large lists, it is not possible to AJAX-enable the page and have users filter....the browser will hang with the long-running script as you outline above.

    It's critical for my users to have the functionality they were used to with the 2007UI.   Unfortunately, the application requires a page that needs SPD customization.   Is there something with modifying the xsl/conditional formatting that is breaking the Show Filter Choices functionality unless the list is dramtically filtered to limit the results?

    With respect to point 4 above, is this something that can be submitted to Microsoft engineers as a fix?   I do not believe that any application should permit functions that will hang a browser function.    Moreover, the user experience should be the same when filtering regardless of whether AJAX is enabled on the page or not.

    Thanks for your help!

    Saturday, July 23, 2011 9:06 PM
  • Hi,

    I have the same problem using SharePoint 2010 with UI in 2007 but this error just happen when the user has the Viewer permissions in the list but if I try to do it with the site collection administrator it works as expected!! This  is the error that I found in the log file:

    Slow Query Duration: 52462.1687228117 F-06a5-4d88-ab7c-330ea15c4226

                          0x0F90 SharePoint Foundation         Database                       fa44 High     Slow Query StackTrace-Managed:    at Microsoft.SharePoint.Utilities.SqlSession.OnPostExecuteCommand(SqlCommand command, SqlQueryData monitoringData)     at Microsoft.SharePoint.Utilities.SqlSession.ExecuteReader(SqlCommand command, CommandBehavior behavior, SqlQueryData monitoringData, Boolean retryForDeadLock)     at Microsoft.SharePoint.SPSqlClient.ExecuteQueryInternal(Boolean retryfordeadlock)     at Microsoft.SharePoint.SPSqlClient.ExecuteQuery(Boolean retryfordeadlock)     at Microsoft.SharePoint.Library.SPRequestInternalClass.GetListItemDataWithCallback2(IListItemSqlClient pSqlClient, String bstrUrl, String bstrListName, String bstrViewName, String bstrViewXml, SAFEARRAYFLAGS fSafeArrayFlags, ISP2DSafeArrayWriter pSACallback, ISPDataCallback pPagingCallback, ISPDataCallback pPagingPr...

                        0x0F90 SharePoint Foundation         Database                       fa44 High     ...evCallback, 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)     at Microsoft.SharePoint.SPListItemCollection.EnsureListItemsData()     at Microsoft.SharePoint.SPListItemCollection.get_Count()     at Microsoft.SharePoint.WebControls.SPDataSourceView.ExecuteSelect(DataSou...

                            0x0F90 SharePoint Foundation         Database                       fa44 High     ...rceSelectArguments selectArguments, String aggregateString, Boolean wantReturn, BaseXsltListWebPart webpart, SPListItem& listItem, SPListItemCollection& listItems, String[]& fieldList)     at Microsoft.SharePoint.WebControls.SingleDataSource.GetXPathNavigatorInternal()     at Microsoft.SharePoint.WebControls.SingleDataSource.GetXPathNavigator()     at Microsoft.SharePoint.WebPartPages.DataFormWebPart.PrepareAndPerformTransform(Boolean bDeferExecuteTransform)     at Microsoft.SharePoint.WebPartPages.DataFormWebPart.PerformSelect()     at Microsoft.SharePoint.WebPartPages.DataFormWebPart.DataBind()     at Microsoft.SharePoint.WebPartPages.DataFormWebPart.EnsureDataBound()     at Microsoft.SharePoint.WebPartPages.DataFormWebPart.CreateChildControls()     at Microsoft.SharePoint.WebPartPages.B...

                            0x0F90 SharePoint Foundation         Database                       fa44 High     ...aseXsltListWebPart.CreateChildControls()     at Microsoft.SharePoint.WebPartPages.WebPartMobileAdapter.CreateChildControls()     at System.Web.UI.Control.EnsureChildControls()     at System.Web.UI.Control.PreRenderRecursiveInternal()     at System.Web.UI.Control.PreRenderRecursiveInternal()     at System.Web.UI.Control.PreRenderRecursiveInternal()     at System.Web.UI.Control.PreRenderRecursiveInternal()     at System.Web.UI.Control.PreRenderRecursiveInternal()     at System.Web.UI.Control.PreRenderRecursiveInternal()     at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)     at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)     at System.Web.UI.Page.ProcessReq...

                          0x0F90 SharePoint Foundation         Database                       fa44 High     ...uest()     at System.Web.UI.Page.ProcessRequest(HttpContext context)     at ASP.VIEWPAGE_ASPX_1777577381.ProcessRequest(HttpContext context)     at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()     at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)     at System.Web.HttpApplication.PipelineStepManager.ResumeSteps(Exception error)     at System.Web.HttpApplication.BeginProcessRequestNotification(HttpContext context, AsyncCallback cb)     at System.Web.HttpRuntime.ProcessRequestNotificationPrivate(IIS7WorkerRequest wr, HttpContext context)     at System.Web.Hosting.PipelineRuntime.ProcessRequestNotificationHelper(IntPtr managedHttpContext, IntPtr nativeRequestContext, IntPtr moduleData, Int...

                          0x0F90 SharePoint Foundation         Database                       fa44 High     ...32 flags)     at System.Web.Hosting.PipelineRuntime.ProcessRequestNotification(IntPtr managedHttpContext, IntPtr nativeRequestContext, IntPtr moduleData, Int32 flags)     at System.Web.Hosting.PipelineRuntime.ProcessRequestNotificationHelper(IntPtr managedHttpContext, IntPtr nativeRequestContext, IntPtr moduleData, Int32 flags)     at System.Web.Hosting.PipelineRuntime.ProcessRequestNotification(IntPtr managedHttpContext, IntPtr nativeRequestContext, IntPtr moduleData, Int32 flags)   d535ba11-06a5-4d88-ab7c-330ea15c4226

                          0x0F90 SharePoint Foundation         Database                       tzku High     ConnectionString: 'Data Source=XXXXXXXXXXX;Initial Catalog=WSS_Content;Integrated Security=True;Enlist=False;Asynchronous Processing=False;Connect Timeout=15'    ConnectionState: Open ConnectionTimeout: 15 d535ba11-06a5-4d88-ab7c-330ea15c4226

     

    Thanks for your help!

    Thursday, August 25, 2011 5:26 PM
  • According to this post and some nice reflector work http://social.msdn.microsoft.com/Forums/en-US/sharepoint2010customization/thread/ad13e5e4-e211-453f-bfef-fe260591154a the XSLT on a page has exactly 1 second to perform a transform in SP2010 before it throws a stack overflow. This was changed in August 2011 to 5 seconds. I am going to install the August 2011 CU and see if this gives my web parts enough time to perform their transforms without throwing a stackoverflow exception.
    Doug Hemminger http://www.sharepointdoug.com
    Monday, October 10, 2011 1:37 PM