I am having a problem with loading data from a CRM dashboard. A user does a search on a grid, the results return quickly, however when they click on the next page the message "Loading records" is displayed, and then eventually a SQL timeout occurs. On the crm server on the event logs the following message is shown:
RequestUrl: https://**REMOVEDURL*/AppWebServices/AppGridWebService.ashx?operation=Refresh, StackTrace: [CrmException: SQL timeout expired.]
at Microsoft.Crm.Application.Platform.ServiceCommands.PlatformCommand.XrmExecuteInternal()
at Microsoft.Crm.Application.Platform.ServiceCommands.RetrieveMultipleCommand.Execute()
at Microsoft.Crm.ApplicationQuery.RetrieveMultipleCommand.RetrieveData()
at Microsoft.Crm.ApplicationQuery.ExecuteQuery()
at Microsoft.Crm.Application.Platform.Grid.GridDataProviderQueryBuilder.GetData(QueryBuilder queryBuilder)
at Microsoft.Crm.Application.Platform.Grid.GridDataProviderQueryBuilder.LoadQueryData()
at Microsoft.Crm.Application.Platform.Grid.GridDataProviderQueryBuilder.LoadData()
at Microsoft.Crm.Application.Platform.Grid.GridDataProviderBase.PrepareGridData()
at Microsoft.Crm.Application.Platform.Grid.GridDataProviderBase.PrepareData()
at Microsoft.Crm.Application.Controls.GridUIProvider.Render(HtmlTextWriter output)
at Microsoft.Crm.Core.Application.WebServices.AppGridWebServiceHandler.GetRefreshResponseHtml(IGridUIProvider uiProvider, StringBuilder sbTemp)
at Microsoft.Crm.Core.Application.WebServices.AppGridWebServiceHandler.Refresh(String gridXml, StringBuilder sbXml, StringBuilder sbHtml, Boolean returnJsonData)
at Microsoft.Crm.Core.Application.WebServices.AppGridWebServiceHandler.ProcessRequestInternal(HttpContext context)
[XmlException: Microsoft.Crm.CrmException: SQL timeout expired.
Other searches and queries within CRM are quick (pagination also works), it is only on the dashboard grid. I have also pasted the SQL query (discovered from the event log) in to SQL server and that runs quickly also.
Any suggestions?






