none
Workflow being terminated with error "Cannot insert duplicate key row in object 'fim.ObjectValueString'" RRS feed

  • Question

  • Hi Folks,

    We keep running into the below error when we are trying to bulk update an attribute in FIM Portal via Powershell. This also occurs when the attribute is being updated for bulk user records with values flowing from Synchronization Service Manager.

    EXCEPTION DATA\r\n\r\nMESSAGE: Microsoft.ResourceManagement.WebServices.Exceptions.UnwillingToPerformException: Other ---> System.Data.SqlClient.SqlException: Reraised Error 50000, Level 14, State 1, Procedure ReRaiseException, Line 37, Message: Reraised Error 50000, Level 14, State 1, Procedure ReRaiseException, Line 37, Message: Reraised Error 2601, Level 14, State 1, Procedure UpdateResource, Line 575, Message: Cannot insert duplicate key row in object 'fim.ObjectValueString' with unique index 'IX_ObjectValueString_ObjectKey_AttributeKey_LocaleKey-Filtered_Multivalued'. The duplicate key value is (12337, 32507, 127).
       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.SqlDataReader.ConsumeMetaData()
       at System.Data.SqlClient.SqlDataReader.get_MetaData()
       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.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method)
       at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method)
       at System.Data.SqlClient.SqlCommand.ExecuteReader()
       at Microsoft.ResourceManagement.Data.DataAccess.ProcessRequest(RequestType request)
       --- End of inner exception stack trace ---
       at Microsoft.ResourceManagement.Utilities.ExceptionManager.ThrowException(Exception exception)
       at Microsoft.ResourceManagement.Data.Exception.DataAccessExceptionManager.ThrowException(SqlException innerException, TransactionAndConnectionScope scope)
       at Microsoft.ResourceManagement.Data.DataAccess.ProcessRequest(RequestType request)
       at Microsoft.ResourceManagement.ActionProcessor.ActionDispatcher.ProcessInputRequest(RequestType request)
       at Microsoft.ResourceManagement.WebServices.RequestDispatcher.ExecuteAction(RequestType request)
       at Microsoft.ResourceManagement.WebServices.RequestDispatcher.ExecuteAction[ResponseBodyType](RequestType request)
       at Microsoft.ResourceManagement.WebServices.RequestDispatcher.DispatchRequest[ResponseBodyType](RequestType request, Guid requestIdentifier, Object redispatchSingleInstanceKey, Boolean isRedispatch)
       at Microsoft.ResourceManagement.WebServices.RequestDispatcher.DispatchRequest[ResponseBodyType](RequestType request)
       at Microsoft.ResourceManagement.Workflow.Hosting.RequestWorkItemProcessor.DispatchRequest[TResponseType](RequestType request, Boolean applyAuthorizationPolicy)
       at Microsoft.ResourceManagement.Workflow.Hosting.RequestWorkItemProcessor.ProcessPutWorkItem(UpdateRequestWorkItem updateWorkItem)
       at Microsoft.ResourceManagement.Workflow.Hosting.RequestWorkItemProcessor.ProcessWorkItem(WorkItem workItem)\r\n\r\n**METHOD:Void ProcessRequestResponse(System.Object, System.Workflow.ComponentModel.QueueEventArgs)\r\n\r\n**METHOD:Boolean Run(System.Workflow.ComponentModel.IWorkflowCoreRuntime)\r\n\r\n**METHOD:Void Run()\r\n\r\n
    ------------------------------------------------------------

    We are having 4.1.3496.0 version of the portal.

    Has someone come across the same error and have any solution for this?

    Thanks,


    Veena

    Friday, July 24, 2015 10:54 AM

All replies

  • Well,

    What is the attribute being updated?  The error clearly states that you are violating uniqueness.


    Nosh Mernacaj, Identity Management Specialist

    Friday, July 24, 2015 12:48 PM
  • Hi Nosh,

    Its a custom group attribute(Custodian Info) within FIM Portal. It holds a string value.

    What do you mean by violationg uniqueness? Can you kindly explain in detail.

     That attribute can have the same value for multiple groups.

    TechNet site states this:

    FIM Service: A request may fail when multiple workflows attempt to modify the same single valued attribute on the same object
    The most likely scenario would be in the PostProcessing phase of a Request in which two or more Action workflows execute in parallel and they are trying to operate on the same object within a narrow time frame.   The Request will fail with PostProcessingError and you will likely find this stack trace in the Event Log.Microsoft.ResourceManagement.WebServices.Exceptions.UnwillingToPerformException:
    Other ---> System.Data.SqlClient.SqlException: Reraised Error 50000, Level 14, State 1, Procedure
    ReRaiseException, Line 37, Message: Reraised Error 50000, Level 14, State 1, Procedure
    ReRaiseException, Line 37, Message: Reraised Error 2601, Level 14, State 1, Procedure
    UpdateResource, Line 525, Message: Cannot insert duplicate key row in object 'fim.ObjectValueString' with unique index
    'IX_ObjectValueString_ObjectKey_AttributeKey_LocaleKey-Filtered_Multivalued'.

    Kindly guide.

    Thanks,


    Veena

    Monday, July 27, 2015 7:48 AM
  • Uniqueness means that only one object in the DB can have that value.

    Example:

    User "User1"  has AccountName="ABC".

    User "User2" cannot have AccountName="ABC"

    The value you are entering is not unique in the DB. What is the attribute you are populating?


    Nosh Mernacaj, Identity Management Specialist

    • Proposed as answer by Nosh Mernacaj Monday, July 27, 2015 2:15 PM
    Monday, July 27, 2015 1:46 PM