none
Falha ao Mover Usuários para outra Unidade de Negócio RRS feed

  • Pergunta

  • Bom dia.

    Srs., alguém consegue me ajudar com a situação abaixo?

    Houve uma reestruturação de hierarquia em nossa empresa e foi preciso criar novas Unidades de Negócio em nosso ambiente para separar os usuários, organizar, etc.

    Porém, quando tentamos mover os usuários para estas novas unidades, o Dynamics nos apresenta um popup de erro e não faz a mudança. Estamos fazendo este processo através da própria ferramenta (Pelo cadastro do usuário, Alterar Unidade de Negócio).

    Popup
    

    Verifiquei que movendo usuários antigos para outras Unidades de Negócio antigas, funcionam muito bem.

    Será que alguém conhece esta falha?

    Dados do Servidor:
    DB: SQL Sever 2008
    Aplicação: Windows 2003 Server R2 com Dynamics CRM 4.0 (Rollups do 5 ao 21).

    Grato
    Anderson

    quarta-feira, 29 de julho de 2015 14:50

Todas as Respostas

  • Boas Anderson,

    Apenas com este screenshot não dá para ajudar muito, eu aconcelhava você a ativar o trace, veja aqui como, e colocar aqui a descrição. Por exemplo as novas unidades de negócio estão ativas?

    Espero ter ajudado.
    Se respondi a sua pergunta por favor marque como resposta e\ou como útil.


    Pedro Azevedo Crm Specialist 4.0\2011

    • Sugerido como Resposta Azevedo PedroMVP quarta-feira, 29 de julho de 2015 17:33
    quarta-feira, 29 de julho de 2015 17:33
  • Boas Anderson,

    Apenas com este screenshot não dá para ajudar muito, eu aconcelhava você a ativar o trace, veja aqui como, e colocar aqui a descrição. Por exemplo as novas unidades de negócio estão ativas?

    Espero ter ajudado.
    Se respondi a sua pergunta por favor marque como resposta e\ou como útil.


    Pedro Azevedo Crm Specialist 4.0\2011

    Olá, obrigado pelo retorno.
    Acredito que a parte do log sobre o erro é esta abaixo:
    Usuário que tentei mover nesta simulação:  E1B15EFB-E922-DF11-8E52-0024E86C7967
    Para a Unidade nova: C57BD723-9F34-E511-928A-000C29DB6ACA

    Erros:

    >MSCRM Error Report:
    --------------------------------------------------------------------------------------------------------
    Error: Exception of type 'System.Web.HttpUnhandledException' was thrown.

    Error Message: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

    Error Details: Exception of type 'System.Web.HttpUnhandledException' was thrown.

    Source File: Not available

    Line Number: Not available

    Request URL: http://spcrm01:5555/Wittel/_grid/cmds/dlg_changeorg.aspx?iObjType=8&iTotal=1&iIndex=0&ownerId={C57BD723-9F34-E511-928A-000C29DB6ACA}&ownerType=10&iId={E1B15EFB-E922-DF11-8E52-0024E86C7967}

    Stack Trace Info: [SqlException: Subquery returned more than 1 value. This is not permitted when the subquery follows =, !=, <, <= , >, >= or when the subquery is used as an expression.
    The statement has been terminated.]
       at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection)
       at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj)
       at System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj)
       at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString)
       at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async)
       at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, DbAsyncResult result)
       at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe)
       at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
       at Microsoft.Crm.CrmDbConnection.InternalExecuteNonQuery(IDbCommand command)
       at Microsoft.Crm.CrmDbConnection.ExecuteNonQuery(IDbCommand command, Boolean impersonate)
       at Microsoft.Crm.BusinessEntities.BusinessProcessObject.ExecuteNonQuery(IDbCommand command, ISqlExecutionContext context)
       at Microsoft.Crm.ObjectModel.SystemUserServiceInternal`1.UpdateBusinessIdForEntity(EntityMetadata entity, Guid userId, Guid businessId, ExecutionContext context)
       at Microsoft.Crm.ObjectModel.SystemUserServiceInternal`1.SetBusinessIdForOwnedObjects(Guid userId, Guid businessId, ExecutionContext context)
       at Microsoft.Crm.ObjectModel.SystemUserServiceInternal`1.SetBusiness(Guid userId, Guid businessId, SecurityPrincipal reassignPrincipal, ExecutionContext context)

    [TargetInvocationException: Exception has been thrown by the target of an invocation.]
       at Microsoft.Crm.Application.Utility.Util.RaiseXMLError(Exception exception)
       at Microsoft.Crm.Dialogs.ChangeOrgDialogPage.ConfigureForm()
       at Microsoft.Crm.Application.Controls.AppUIPage.OnPreRender(EventArgs e)
       at System.Web.UI.Control.PreRenderRecursiveInternal()
       at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

    [HttpUnhandledException: Exception of type 'System.Web.HttpUnhandledException' was thrown.]
       at System.Web.UI.Page.HandleError(Exception e)
       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.ProcessRequest()
       at System.Web.UI.Page.ProcessRequest(HttpContext context)
       at ASP.wittel__grid_cmds_dlg_changeorg_aspx.ProcessRequest(HttpContext context)
       at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
       at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)


    [2015-07-29 17:28:24.7] Process: w3wp |Organization:00000000-0000-0000-0000-000000000000 |Thread:    1 |Category: Platform |User: 00000000-0000-0000-0000-000000000000 |Level: Info | MiniDump.CreateDumpInternal
    at MiniDump.CreateDumpInternal(MiniDumpReasons reason, Exception exception)
    at MiniDump.CreateDump(MiniDumpReasons reason, Exception exception)
    at MainApplication.Application_Error(Object sender, EventArgs eventArguments)
    at EventHandler.Invoke(Object sender, EventArgs e)
    at HttpApplication.RaiseOnError()
    at ApplicationStepManager.ResumeSteps(Exception error)
    at HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData)
    at HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)
    at HttpRuntime.ProcessRequestNoDemand(HttpWorkerRequest wr)
    at ISAPIRuntime.ProcessRequest(IntPtr ecb, Int32 iWRType)
    >MiniDump: TraceDirectory setting not set or missing. Defaulting to temporary folder.
    [2015-07-29 17:28:24.7] Process: w3wp |Organization:00000000-0000-0000-0000-000000000000 |Thread:    1 |Category: Platform |User: 00000000-0000-0000-0000-000000000000 |Level: Info | MiniDump.CreateDumpInternal
    at MiniDump.CreateDumpInternal(MiniDumpReasons reason, Exception exception)
    at ExceptionManager.ReportException(Exception exception, String format, Object[] args)
    at MainApplication.Application_Error(Object sender, EventArgs eventArguments)
    at EventHandler.Invoke(Object sender, EventArgs e)
    at HttpApplication.RaiseOnError()
    at ApplicationStepManager.ResumeSteps(Exception error)
    at HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData)
    at HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)
    at HttpRuntime.ProcessRequestNoDemand(HttpWorkerRequest wr)
    at ISAPIRuntime.ProcessRequest(IntPtr ecb, Int32 iWRType)
    >MiniDump: TraceDirectory setting not set or missing. Defaulting to temporary folder.
    [2015-07-29 17:28:24.7] Process: w3wp |Organization:00000000-0000-0000-0000-000000000000 |Thread:    1 |Category: Platform |User: 00000000-0000-0000-0000-000000000000 |Level: Verbose | SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute
    at SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
    at HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
    at ApplicationStepManager.ResumeSteps(Exception error)
    at HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData)
    at HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)
    at HttpRuntime.ProcessRequestNoDemand(HttpWorkerRequest wr)
    at ISAPIRuntime.ProcessRequest(IntPtr ecb, Int32 iWRType)
    >MapOrgEngine: Retreived the OrgId[{5102B778-82A6-44B5-A715-CED4A6CE2A89}] for URL[http://spcrm01:5555/Wittel/_common/error/dlg_error.aspx?hresult=2147500037&errMessage=].
    [2015-07-29 17:28:24.7] Process: w3wp |Organization:00000000-0000-0000-0000-000000000000 |Thread:    1 |Category: Platform |User: 00000000-0000-0000-0000-000000000000 |Level: Verbose | SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute
    at SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
    at HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
    at ApplicationStepManager.ResumeSteps(Exception error)
    at HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData)
    at HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)
    at HttpRuntime.ProcessRequestNoDemand(HttpWorkerRequest wr)
    at ISAPIRuntime.ProcessRequest(IntPtr ecb, Int32 iWRType)
    >AUTH: Request [GET http://spcrm01:5555/Wittel/_common/error/dlg_error.aspx?hresult=2147500037&errMessage=] entered Authentication Pipeline.
    [2015-07-29 17:28:24.7] Process: w3wp |Organization:00000000-0000-0000-0000-000000000000 |Thread:    1 |Category: Platform |User: 00000000-0000-0000-0000-000000000000 |Level: Verbose | AuthenticationPipeline.Authenticate
    at AuthenticationPipeline.Authenticate(HttpApplication application)
    at AuthenticationEngine.Execute(Object sender, EventArgs e)
    at SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
    at HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
    at ApplicationStepManager.ResumeSteps(Exception error)
    at HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData)
    at HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)
    at HttpRuntime.ProcessRequestNoDemand(HttpWorkerRequest wr)
    at ISAPIRuntime.ProcessRequest(IntPtr ecb, Int32 iWRType)
    >AUTH: AuthenticationProvider [Microsoft.Crm.Authentication.WindowsAuthenticationProvider] will be atempted.
    [2015-07-29 17:28:24.7] Process: w3wp |Organization:00000000-0000-0000-0000-000000000000 |Thread:    1 |Category: Platform.Sql |User: 00000000-0000-0000-0000-000000000000 |Level: Info | CrmDbConnection.ExecuteReader
    at CrmDbConnection.ExecuteReader(IDbCommand command, Boolean impersonate)
    at ServerLocatorService.TryGetCrmUserIdFromDatabase(Guid organizationId, String authenticationInfo, Guid& crmUserId)
    at ServerLocatorService.TryGetCrmUserId(Guid organizationId, String authenticationInfo, Guid& crmUserId)
    at LocatorService.TryGetCrmUserId(Guid organizationId, String authenticationInfo, Guid& crmUserId)
    at SecurityLibrary.GetUserInfoInternal(WindowsIdentity identity, IOrganizationContext context, UserAuth& userInfo)
    at SecurityLibrary.GetCallerAndBusinessGuidsFromThread(WindowsIdentity identity, Guid organizationId)
    at CrmWindowsIdentity..ctor(WindowsIdentity innerIdentity, Boolean publishCrmUser, Guid organizationId)
    at WindowAuthenticationProviderBase.Authenticate(HttpApplication application)
    at AuthenticationStep.Authenticate(HttpApplication application)
    at AuthenticationPipeline.Authenticate(HttpApplication application)
    at AuthenticationEngine.Execute(Object sender, EventArgs e)
    at SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
    at HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
    at ApplicationStepManager.ResumeSteps(Exception error)
    at HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData)
    at HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)
    at HttpRuntime.ProcessRequestNoDemand(HttpWorkerRequest wr)
    at ISAPIRuntime.ProcessRequest(IntPtr ecb, Int32 iWRType)
    >exec p_GetCrmUserId '5102b778-82a6-44b5-a715-ced4a6ce2a89', 'W:S-1-5-21-591287042-73040229-1372050218-7214'
    [2015-07-29 17:28:24.7] Process: w3wp |Organization:00000000-0000-0000-0000-000000000000 |Thread:    1 |Category: Platform |User: 00000000-0000-0000-0000-000000000000 |Level: Verbose | WindowAuthenticationProviderBase.Authenticate
    at WindowAuthenticationProviderBase.Authenticate(HttpApplication application)
    at AuthenticationStep.Authenticate(HttpApplication application)
    at AuthenticationPipeline.Authenticate(HttpApplication application)
    at AuthenticationEngine.Execute(Object sender, EventArgs e)
    at SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
    at HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
    at ApplicationStepManager.ResumeSteps(Exception error)
    at HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData)
    at HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)
    at HttpRuntime.ProcessRequestNoDemand(HttpWorkerRequest wr)
    at ISAPIRuntime.ProcessRequest(IntPtr ecb, Int32 iWRType)
    >WindowsAuthenticationProvider published CrmWindowsIdentity [UserToken:W:S-1-5-21-591287042-73040229-1372050218-7214] [UserId:{2C23B971-69D4-DE11-9A47-0024E86C7967}].
    [2015-07-29 17:28:24.7] Process: w3wp |Organization:00000000-0000-0000-0000-000000000000 |Thread:    1 |Category: Platform |User: 00000000-0000-0000-0000-000000000000 |Level: Info | AuthenticationPipeline.Authenticate
    at AuthenticationPipeline.Authenticate(HttpApplication application)
    at AuthenticationEngine.Execute(Object sender, EventArgs e)
    at SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
    at HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
    at ApplicationStepManager.ResumeSteps(Exception error)
    at HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData)
    at HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)
    at HttpRuntime.ProcessRequestNoDemand(HttpWorkerRequest wr)
    at ISAPIRuntime.ProcessRequest(IntPtr ecb, Int32 iWRType)
    >AUTH: AuthenticationProvider [Microsoft.Crm.Authentication.WindowsAuthenticationProvider] handled request [http://spcrm01:5555/Wittel/_common/error/dlg_error.aspx?hresult=2147500037&errMessage=].
    [2015-07-29 17:28:24.7] Process: w3wp |Organization:00000000-0000-0000-0000-000000000000 |Thread:    1 |Category: Platform |User: 00000000-0000-0000-0000-000000000000 |Level: Verbose | BuildResult.ComputeSourceDependenciesHashCode
    at BuildResult.ComputeSourceDependenciesHashCode(VirtualPath virtualPath)
    at BuildResult.IsUpToDate(VirtualPath virtualPath)
    at MemoryBuildResultCache.GetBuildResult(String cacheKey, VirtualPath virtualPath, Int64 hashCode)
    at BuildManager.GetBuildResultFromCacheInternal(String cacheKey, Boolean keyFromVPP, VirtualPath virtualPath, Int64 hashCode)
    at BuildManager.GetVPathBuildResultInternal(VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile)
    at BuildManager.GetVPathBuildResultWithNoAssert(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile)
    at BuildManager.GetVirtualPathObjectFactory(VirtualPath virtualPath, HttpContext context, Boolean allowCrossApp, Boolean noAssert)
    at BuildManager.CreateInstanceFromVirtualPath(VirtualPath virtualPath, Type requiredBaseType, HttpContext context, Boolean allowCrossApp, Boolean noAssert)
    at PageHandlerFactory.GetHandlerHelper(HttpContext context, String requestType, VirtualPath virtualPath, String physicalPath)
    at HttpApplication.MapHttpHandler(HttpContext context, String requestType, VirtualPath path, String pathTranslated, Boolean useAppConfig)
    at MapHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
    at HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
    at ApplicationStepManager.ResumeSteps(Exception error)
    at HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData)
    at HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)
    at HttpRuntime.ProcessRequestNoDemand(HttpWorkerRequest wr)
    at ISAPIRuntime.ProcessRequest(IntPtr ecb, Int32 iWRType)
    >GetFileHash(/Wittel/_common/error/dlg_error.aspx, System.Collections.ArrayList) called.
    [2015-07-29 17:28:24.7] Process: w3wp |Organization:5102b778-82a6-44b5-a715-ced4a6ce2a89 |Thread:    1 |Category: Application |User: 00000000-0000-0000-0000-000000000000 |Level: Info | Util.TraceMessage
    at Util.TraceMessage(TraceLevel level, String message, Object[] args)
    at AppForm.ConfigureControl()
    at CrmUIControlBase.ConfigureControlInternal()
    at Control.PreRenderRecursiveInternal()
    at Control.PreRenderRecursiveInternal()
    at Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
    at Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
    at Page.ProcessRequest()
    at Page.ProcessRequest(HttpContext context)
    at wittel__common_error_dlg_error_aspx.ProcessRequest(HttpContext context)
    at CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
    at HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
    at ApplicationStepManager.ResumeSteps(Exception error)
    at HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData)
    at HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)
    at HttpRuntime.ProcessRequestNoDemand(HttpWorkerRequest wr)
    at ISAPIRuntime.ProcessRequest(IntPtr ecb, Int32 iWRType)
    >UserId ({2C23B971-69D4-DE11-9A47-0024E86C7967}): AppForm.ConfigureControl: QueryString : /Wittel/_common/error/dlg_error.aspx?hresult=2147500037&errMessage=
    [2015-07-29 17:28:24.7] Process: w3wp |Organization:00000000-0000-0000-0000-000000000000 |Thread:    1 |Category: Platform.Sql |User: 00000000-0000-0000-0000-000000000000 |Level: Verbose | CrmConfigSettingsService.GetHelpServerData
    at CrmConfigSettingsService.GetHelpServerData()
    at AppHeader.AddGlobalValues()
    at Header.PrepareHeader()
    at Header.Render(HtmlTextWriter output)
    at Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children)
    at Page.Render(HtmlTextWriter writer)
    at Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
    at Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
    at Page.ProcessRequest()
    at Page.ProcessRequest(HttpContext context)
    at wittel__common_error_dlg_error_aspx.ProcessRequest(HttpContext context)
    at CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
    at HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
    at ApplicationStepManager.ResumeSteps(Exception error)
    at HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData)
    at HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)
    at HttpRuntime.ProcessRequestNoDemand(HttpWorkerRequest wr)
    at ISAPIRuntime.ProcessRequest(IntPtr ecb, Int32 iWRType)
    >HetHelpServerData)
    [2015-07-29 17:28:24.7] Process: w3wp |Organization:00000000-0000-0000-0000-000000000000 |Thread:    1 |Category: Platform.Sql |User: 00000000-0000-0000-0000-000000000000 |Level: Verbose | CrmConfigSettingsService.Retrieve
    at CrmConfigSettingsService.Retrieve(String[] columns)
    at CrmConfigSettingsService.GetHelpServerData()
    at AppHeader.AddGlobalValues()
    at Header.PrepareHeader()
    at Header.Render(HtmlTextWriter output)
    at Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children)
    at Page.Render(HtmlTextWriter writer)
    at Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
    at Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
    at Page.ProcessRequest()
    at Page.ProcessRequest(HttpContext context)
    at wittel__common_error_dlg_error_aspx.ProcessRequest(HttpContext context)
    at CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
    at HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
    at ApplicationStepManager.ResumeSteps(Exception error)
    at HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData)
    at HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)
    at HttpRuntime.ProcessRequestNoDemand(HttpWorkerRequest wr)
    at ISAPIRuntime.ProcessRequest(IntPtr ecb, Int32 iWRType)
    >Retrieve ConfigSettings, Id=({43E2CF02-D524-4E0E-9555-6211701D462D})
    [2015-07-29 17:28:24.7] Process: w3wp |Organization:00000000-0000-0000-0000-000000000000 |Thread:    1 |Category: Platform.Sql |User: 00000000-0000-0000-0000-000000000000 |Level: Info | CrmDbConnection.ExecuteReader
    at CrmDbConnection.ExecuteReader(IDbCommand command, Boolean impersonate)
    at DatabaseService.ExecuteBaseReader(CrmDbConnection connection, IDbCommand command, String[] columns)
    at DatabaseService.Retrieve(String tableName, String[] columns, PropertyBag[] conditions)
    at DatabaseService.RetrieveById(String tableName, Object id, String[] columns)
    at CrmConfigSettingsService.Retrieve(String[] columns)
    at CrmConfigSettingsService.GetHelpServerData()
    at AppHeader.AddGlobalValues()
    at Header.PrepareHeader()
    at Header.Render(HtmlTextWriter output)
    at Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children)
    at Page.Render(HtmlTextWriter writer)
    at Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
    at Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
    at Page.ProcessRequest()
    at Page.ProcessRequest(HttpContext context)
    at wittel__common_error_dlg_error_aspx.ProcessRequest(HttpContext context)
    at CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
    at HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
    at ApplicationStepManager.ResumeSteps(Exception error)
    at HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData)
    at HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)
    at HttpRuntime.ProcessRequestNoDemand(HttpWorkerRequest wr)
    at ISAPIRuntime.ProcessRequest(IntPtr ecb, Int32 iWRType)
    >SELECT Id, HelpServerUrl, InstallOn, IsRegistered, LicenseKey, PrivilegeReportGroupId, PrivilegeUserGroupId, ProductId, RegistrationId, RegistrationXml, ReportingGroupId, SqlAccessGroupId, UserGroupId FROM ConfigSettings  WHERE (((Id = '43e2cf02-d524-4e0e-9555-6211701d462d')) ) AND (IsDeleted = 0)
    [2015-07-29 17:28:24.7] Process: w3wp |Organization:00000000-0000-0000-0000-000000000000 |Thread:    1 |Category: Platform.Sql |User: 00000000-0000-0000-0000-000000000000 |Level: Info | CrmDbConnection.ExecuteReader
    at CrmDbConnection.ExecuteReader(IDbCommand command, Boolean impersonate)
    at DatabaseService.ExecutePropertiesReader(CrmDbConnection connection, IDbCommand command, String[] columns, PropertyBagCollection resultSet)
    at DatabaseService.Retrieve(String tableName, String[] columns, PropertyBag[] conditions)
    at DatabaseService.RetrieveById(String tableName, Object id, String[] columns)
    at CrmConfigSettingsService.Retrieve(String[] columns)
    at CrmConfigSettingsService.GetHelpServerData()
    at AppHeader.AddGlobalValues()
    at Header.PrepareHeader()
    at Header.Render(HtmlTextWriter output)
    at Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children)
    at Page.Render(HtmlTextWriter writer)
    at Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
    at Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
    at Page.ProcessRequest()
    at Page.ProcessRequest(HttpContext context)
    at wittel__common_error_dlg_error_aspx.ProcessRequest(HttpContext context)
    at CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
    at HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
    at ApplicationStepManager.ResumeSteps(Exception error)
    at HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData)
    at HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)
    at HttpRuntime.ProcessRequestNoDemand(HttpWorkerRequest wr)
    at ISAPIRuntime.ProcessRequest(IntPtr ecb, Int32 iWRType)
    >SELECT Id, ColumnName, BigIntColumn, IntColumn, SmallIntColumn, TinyIntColumn, BitColumn, FloatColumn, DateTimeColumn, SmallDateTimeColumn, NVarCharColumn, UniqueIdentifierColumn, VarBinaryColumn FROM ConfigSettingsProperties WHERE Id IN (SELECT Id FROM ConfigSettings WHERE (((Id = '43e2cf02-d524-4e0e-9555-6211701d462d')) ) AND (IsDeleted = 0))
    [2015-07-29 17:28:24.7] Process: w3wp |Organization:00000000-0000-0000-0000-000000000000 |Thread:    1 |Category: Platform.Sql |User: 00000000-0000-0000-0000-000000000000 |Level: Verbose | CrmConfigSettingsService.GetHelpServerData
    at CrmConfigSettingsService.GetHelpServerData()
    at AppHeader.AddGlobalValues()
    at Header.PrepareHeader()
    at Header.Render(HtmlTextWriter output)
    at Control.RenderChildrenInternal(HtmlTextWriter writer, ICollection children)
    at Page.Render(HtmlTextWriter writer)
    at Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
    at Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
    at Page.ProcessRequest()
    at Page.ProcessRequest(HttpContext context)
    at wittel__common_error_dlg_error_aspx.ProcessRequest(HttpContext context)
    at CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
    at HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
    at ApplicationStepManager.ResumeSteps(Exception error)
    at HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData)
    at HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)
    at HttpRuntime.ProcessRequestNoDemand(HttpWorkerRequest wr)
    at ISAPIRuntime.ProcessRequest(IntPtr ecb, Int32 iWRType)
    >GetHelpServerData, HelpServerUrl=
    [2015-07-29 17:28:24.8] Process: w3wp |Organization:00000000-0000-0000-0000-000000000000 |Thread:   19 |Category: Platform |User: 00000000-0000-0000-0000-000000000000 |Level: Verbose | SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute
    at SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
    at HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
    at ApplicationStepManager.ResumeSteps(Exception error)
    at HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData)
    at HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)
    at HttpRuntime.ProcessRequestNoDemand(HttpWorkerRequest wr)
    at ISAPIRuntime.ProcessRequest(IntPtr ecb, Int32 iWRType)
    >MapOrgEngine: Retreived the OrgId[{00000000-0000-0000-0000-000000000000}] for URL[http://spcrm01:5555/MSCRMServices/2007/CrmService.asmx].
    [2015-07-29 17:28:24.8] Process: w3wp |Organization:00000000-0000-0000-0000-000000000000 |Thread:   19 |Category: Platform |User: 00000000-0000-0000-0000-000000000000 |Level: Verbose | SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute
    at SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
    at HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
    at ApplicationStepManager.ResumeSteps(Exception error)
    at HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData)
    at HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)
    at HttpRuntime.ProcessRequestNoDemand(HttpWorkerRequest wr)
    at ISAPIRuntime.ProcessRequest(IntPtr ecb, Int32 iWRType)
    >AUTH: Request [POST http://spcrm01:5555/MSCRMServices/2007/CrmService.asmx] entered Authentication Pipeline.
    [2015-07-29 17:28:24.8] Process: w3wp |Organization:00000000-0000-0000-0000-000000000000 |Thread:   19 |Category: Platform |User: 00000000-0000-0000-0000-000000000000 |Level: Verbose | AuthenticationPipeline.Authenticate
    at AuthenticationPipeline.Authenticate(HttpApplication application)
    at AuthenticationEngine.Execute(Object sender, EventArgs e)
    at SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
    at HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
    at ApplicationStepManager.ResumeSteps(Exception error)
    at HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData)
    at HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)
    at HttpRuntime.ProcessRequestNoDemand(HttpWorkerRequest wr)
    at ISAPIRuntime.ProcessRequest(IntPtr ecb, Int32 iWRType)
    >AUTH: AuthenticationProvider [Microsoft.Crm.WebServices.Crm2007.MultipleOrganizationSoapHeaderAuthenticationProvider] will be atempted.
    [2015-07-29 17:28:24.8] Process: w3wp |Organization:00000000-0000-0000-0000-000000000000 |Thread:   19 |Category: Platform |User: 00000000-0000-0000-0000-000000000000 |Level: Verbose | WindowAuthenticationProviderBase.Authenticate
    at WindowAuthenticationProviderBase.Authenticate(HttpApplication application)
    at AuthenticationProvider.Authenticate(CrmAuthenticationToken token)
    at SoapHeaderAuthenticationProviderBase.Authenticate(HttpApplication application)
    at AuthenticationStep.Authenticate(HttpApplication application)
    at AuthenticationPipeline.Authenticate(HttpApplication application)
    at AuthenticationEngine.Execute(Object sender, EventArgs e)
    at SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
    at HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
    at ApplicationStepManager.ResumeSteps(Exception error)
    at HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData)
    at HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)
    at HttpRuntime.ProcessRequestNoDemand(HttpWorkerRequest wr)
    at ISAPIRuntime.ProcessRequest(IntPtr ecb, Int32 iWRType)
    >WindowsAuthenticationProvider published CrmWindowsIdentity [UserToken:W:S-1-5-21-591287042-73040229-1372050218-7341] [UserId:{00000000-0000-0000-0000-000000000000}].
    [2015-07-29 17:28:24.8] Process: w3wp |Organization:00000000-0000-0000-0000-000000000000 |Thread:   19 |Category: Platform.Sql |User: 00000000-0000-0000-0000-000000000000 |Level: Info | CrmDbConnection.ExecuteReader
    at CrmDbConnection.ExecuteReader(IDbCommand command, Boolean impersonate)
    at ServerLocatorService.TryGetCrmUserIdFromDatabase(Guid organizationId, String authenticationInfo, Guid& crmUserId)
    at ServerLocatorService.TryGetCrmUserId(Guid organizationId, String authenticationInfo, Guid& crmUserId)
    at LocatorService.TryGetCrmUserId(Guid organizationId, String authenticationInfo, Guid& crmUserId)
    at SecurityLibrary.GetUserInfoInternal(WindowsIdentity identity, IOrganizationContext context, UserAuth& userInfo)
    at SecurityLibrary.GetCallerAndBusinessGuidsFromThread(WindowsIdentity identity, Guid organizationId)
    at CrmWindowsIdentity.DoRecognizeUser(String userToken, Guid organizationId)
    at BaseCrmIdentity.RecognizeCrmUser(Guid organizationId)
    at CrmWindowsIdentity.RecognizeCrmUser(Guid organizationId, Guid callerId)
    at AuthenticationProvider.Authenticate(CrmAuthenticationToken token)
    at SoapHeaderAuthenticationProviderBase.Authenticate(HttpApplication application)
    at AuthenticationStep.Authenticate(HttpApplication application)
    at AuthenticationPipeline.Authenticate(HttpApplication application)
    at AuthenticationEngine.Execute(Object sender, EventArgs e)
    at SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
    at HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
    at ApplicationStepManager.ResumeSteps(Exception error)
    at HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData)
    at HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)
    at HttpRuntime.ProcessRequestNoDemand(HttpWorkerRequest wr)
    at ISAPIRuntime.ProcessRequest(IntPtr ecb, Int32 iWRType)
    >exec p_GetCrmUserId '5102b778-82a6-44b5-a715-ced4a6ce2a89', 'W:S-1-5-21-591287042-73040229-1372050218-7341'
    [2015-07-29 17:28:24.8] Process: w3wp |Organization:00000000-0000-0000-0000-000000000000 |Thread:   19 |Category: Platform |User: 00000000-0000-0000-0000-000000000000 |Level: Info | AuthenticationPipeline.Authenticate
    at AuthenticationPipeline.Authenticate(HttpApplication application)
    at AuthenticationEngine.Execute(Object sender, EventArgs e)
    at SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
    at HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
    at ApplicationStepManager.ResumeSteps(Exception error)
    at HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData)
    at HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)
    at HttpRuntime.ProcessRequestNoDemand(HttpWorkerRequest wr)
    at ISAPIRuntime.ProcessRequest(IntPtr ecb, Int32 iWRType)
    >AUTH: AuthenticationProvider [Microsoft.Crm.WebServices.Crm2007.MultipleOrganizationSoapHeaderAuthenticationProvider] handled request [http://spcrm01:5555/MSCRMServices/2007/CrmService.asmx].
    [2015-07-29 17:28:24.8] Process: w3wp |Organization:5102b778-82a6-44b5-a715-ced4a6ce2a89 |Thread:   19 |Category: Platform.Soap |User: de22e71d-a61d-df11-8e52-0024e86c7967 |Level: Verbose | SoapContext.DumpInfo
    at SoapContext.DumpInfo()
    at CrmAuthenticationSoapExtensionBase.InitializeSoapAndSerializationContexts(UserAuth userInfo, Guid callerId, SoapContext soapContext)
    at CrmAuthenticationSoapExtensionBase.ProcessMessage(SoapMessage message)
    at SoapMessage.RunExtensions(SoapExtension[] extensions, Boolean throwOnException)
    at SoapServerProtocol.ReadParameters()
    at WebServiceHandler.CoreProcessRequest()
    at SyncSessionlessHandler.ProcessRequest(HttpContext context)
    at CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
    at HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
    at ApplicationStepManager.ResumeSteps(Exception error)
    at HttpApplication.System.Web.IHttpAsyncHandler.BeginProcessRequest(HttpContext context, AsyncCallback cb, Object extraData)
    at HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)
    at HttpRuntime.ProcessRequestNoDemand(HttpWorkerRequest wr)
    at ISAPIRuntime.ProcessRequest(IntPtr ecb, Int32 iWRType)

    quarta-feira, 29 de julho de 2015 20:54
  • Alguém conseguiu saber onde há falhas, pelo log apresentado?
    quinta-feira, 6 de agosto de 2015 13:53
  • Boas Anderson,

    Traduzindo um pouco a mensagem é que o CRM está a efetuar uma query e está a dar mais que um resultado quando era expectável apenas um, agora é difícil dizer onde ele no log mostra dois selects,vê se retornam mais que um resultado:

    SELECT Id, HelpServerUrl, InstallOn, IsRegistered, LicenseKey, PrivilegeReportGroupId, PrivilegeUserGroupId, ProductId, RegistrationId, RegistrationXml, ReportingGroupId, SqlAccessGroupId, UserGroupId FROM ConfigSettings  WHERE (((Id = '43e2cf02-d524-4e0e-9555-6211701d462d')) ) AND (IsDeleted = 0)
    
    SELECT Id, ColumnName, BigIntColumn, IntColumn, SmallIntColumn, TinyIntColumn, BitColumn, FloatColumn, DateTimeColumn, SmallDateTimeColumn, NVarCharColumn, UniqueIdentifierColumn, VarBinaryColumn FROM ConfigSettingsProperties WHERE Id IN (SELECT Id FROM ConfigSettings WHERE (((Id = '43e2cf02-d524-4e0e-9555-6211701d462d')) ) AND (IsDeleted = 0))

    Por exemplo essas unidades de negócio já existiram?

    Espero ter ajudado.
    Se respondi a sua pergunta por favor marque como resposta e\ou como útil.


    Pedro Azevedo Crm Specialist 4.0\2011

    domingo, 9 de agosto de 2015 00:02
  • Olá Pedro.

    Não, essas unidades são novas e foram criadas por mim.
    terça-feira, 18 de agosto de 2015 20:32
  • Boas Anderson,

    E o resultado das queries conseguiu obter?

    Espero ter ajudado.
    Se respondi a sua pergunta por favor marque como resposta e\ou como útil.


    Pedro Azevedo Crm Specialist 4.0\2011

    quarta-feira, 9 de setembro de 2015 13:56
  • Olá Pedro, obrigado pelo retorno.

    Executei as Queries e a segunda traz dois resultados.

    Resultado da query que mostrou 2 linhas:

     anexo

    Consegue me ajudar?

    Grato
    Anderson

    segunda-feira, 14 de setembro de 2015 14:33
  • Boas Anderson,

    Pois não ajudou muito, um dos problemas que eu tinha quando estava a fazer estas operações eram problemas de timeout, tenta aplicar este KB da microsoft.

    Uma solução poderá por fazeres isso através de uma utility com o seguinte código:

    SetBusinessSystemUserRequest sbsur = 
    new SetBusinessSystemUserRequest();
    sbsur.BusinessId = businessId;                                            
    SecurityPrincipal sp = new SecurityPrincipal();
    sp.PrincipalId =  Guid.Empty;
    sbsur.ReassignPrincipal = sp;                                           
    sbsur.UserId = movingUserId;
    Espero ter ajudado.
    Se respondi a sua pergunta por favor marque como resposta e\ou como útil.


    Pedro Azevedo Crm Specialist 4.0\2011

    • Sugerido como Resposta Azevedo PedroMVP terça-feira, 22 de setembro de 2015 23:37
    terça-feira, 22 de setembro de 2015 23:36