Asked by:
a sql server error occurred. try this action again.

Question
-
I've CRM 2011 on-premise installation. When a workflow (both custom and crm workflow) try to a create note in Account entity, an error occurred. When I check the workflow status it shows ‘Waiting’ and showing below error message.
“A SQL Server error occurred. Try this action again. If the problem continues check the Microsoft Dynamics CRM Community for solutions or contact your organization's Microsoft Dynamics CRM Administrator. Finally, you can contact Microsoft Support”
Workflow paused due to error: Unhandled Exception: System.ServiceModel.FaultException`1[[Microsoft.Xrm.Sdk.OrganizationServiceFault, Microsoft.Xrm.Sdk, Version=5.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]: Generic SQL error.Detail:
<OrganizationServiceFault xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.microsoft.com/xrm/2011/Contracts">
<ErrorCode>-2147204784</ErrorCode>
<ErrorDetails xmlns:d2p1="http://schemas.datacontract.org/2004/07/System.Collections.Generic" />
<Message>Generic SQL error.</Message>
<Timestamp>2012-10-25T11:11:01.2064949Z</Timestamp>
<InnerFault>
<ErrorCode>-2147204784</ErrorCode>
<ErrorDetails xmlns:d3p1="http://schemas.datacontract.org/2004/07/System.Collections.Generic" />
<Message>Generic SQL error.</Message>
<Timestamp>2012-10-25T11:11:01.2064949Z</Timestamp>
<InnerFault>
<ErrorCode>-2147220970</ErrorCode>
<ErrorDetails xmlns:d4p1="http://schemas.datacontract.org/2004/07/System.Collections.Generic" />
<Message>System.Data.SqlClient.SqlException: Microsoft Dynamics CRM has experienced an error. Reference number for administrators or support: #6F1D18EA</Message>
<Timestamp>2012-10-25T11:11:01.207495Z</Timestamp>
<InnerFault i:nil="true" />
<TraceText i:nil="true" />
</InnerFault>
<TraceText i:nil="true" />
</InnerFault>
<TraceText i:nil="true" />
</OrganizationServiceFault>
at Microsoft.Crm.Extensibility.OrganizationSdkServiceInternal.RetrieveMultiple(QueryBase query, CorrelationToken correlationToken, CallerOriginToken callerOriginToken, WebServiceType serviceType)
at Microsoft.Crm.Extensibility.InprocessServiceProxy.RetrieveMultipleCore(QueryBase query)
at Microsoft.Crm.Workflow.RegardingObjectUtility.CreateLookup(String entityName, Guid entityId)
at Microsoft.Crm.Workflow.WorkflowContextBase.SetStepRegardingRecord(String entityName, Guid entityId)
at Microsoft.Crm.Workflow.Services.UpdateActivityService.<>c__DisplayClass1.<UpdateInternal>b__0(IOrganizationService sdkService)
at Microsoft.Crm.Workflow.Services.ActivityServiceBase.ExecuteInTransactedContext(ActivityDelegate activityDelegate)
at Microsoft.Crm.Workflow.Services.UpdateActivityService.UpdateInternal(Entity entity, String stepId)
at Microsoft.Crm.Workflow.Services.UpdateActivityService.ExecuteInternal(ActivityContext executionContext, UpdateEntity updateEntity)
at Microsoft.Crm.Workflow.Services.UpdateActivityService.Execute(ActivityContext executionContext, UpdateEntity updateEntity)
at System.Activities.CodeActivity.InternalExecute(ActivityInstance instance, ActivityExecutor executor, BookmarkManager bookmarkManager)
at System.Activities.Runtime.ActivityExecutor.ExecuteActivityWorkItem.ExecuteBody(ActivityExecutor executor, BookmarkManager bookmarkManager, Location resultLocation)
Please suggest,
Thanks
Kiran
Friday, November 16, 2012 2:23 PM
All replies
-
The first thing to do is enable tracing, and see if that gives a more useful error message
Microsoft CRM MVP - http://mscrmuk.blogspot.com/ http://www.excitation.co.uk
Friday, November 16, 2012 8:19 PMModerator -
Hi,
Try Restarting the "Workstation Service" in your Server, since the Workflows depends on this service as Network delay may cause Error.
Naren
Monday, November 19, 2012 10:53 AM -
David,
provided error description taken from error tracing only.
Naren,
I've done this. no network issues.
Any suggestions ?
Monday, November 19, 2012 1:03 PM -
Hi.
I would suggest to run a "lock trace" in SQL server profiler to see if you have a dead lock issue.
Regards,
//Hans
hanslinder
Thursday, December 13, 2012 10:22 PM -
- check if you see any event viewer errors on SQL server any deadlocks ?
-make sure if it is a custom workflow activity that you have registered through plugin registration , it is regsietered in isolation mode none as custom workflows cannot be registered on Sandbox Mode. It is not supported yet.
-Check the size of asyncoperationbase table - if it is huge please run a cleanup script
-add OledbTimeout and ExtendedTimeout Reg key on CRM server
-Check if a normal workflow with simple logic works? If No then entries in deploymentproperties table are incorrect in config database.
-See if other system jobs are working fine
Please answer all above question and I can give you next action plan.
Arpita
Wednesday, December 19, 2012 3:57 AM -
hi Arpita,
Initially I've tried all above cases everything working fine, actually its not regular error. I found this error weekly twice or thrice, but the horrible thing is the number is increasing, now its 20 per week.
any other clues more appreciable.
Kiran.
Thursday, December 20, 2012 7:02 AM