Solved

Why are we getting a SQL error when trying to re-assign a record in MS CRM 2013

Posted on 2016-07-29
6
84 Views
Last Modified: 2016-08-12
Hi everyone,

Since migrating from MS CRM 4.0 to 2011 and then immediately from 2011 to 2013, the "Assign" feature is no longer working for some records. We cannot re-assign those records using the Assign button or the lookup field regardless of our security role (even System Administrator). When we try it we get a SQL error and the log file says there is a duplicate activity owner.

We have been able to work around this temporarily by changing the "Assigned To" user from the SQL database directly for some specific records but this is bad practice.

We are trying to figure out how to fix those records permanently the right way. Does anyone have a clue to why it is doing this and how we can fix it permanently?

Thank you,
Stéphane Laplante
0
Comment
Question by:IT-Services-TI
  • 3
  • 3
6 Comments
 
LVL 19

Expert Comment

by:Rikin Shah
ID: 41734704
Hi,

Can you post the logs here?
0
 

Author Comment

by:IT-Services-TI
ID: 41734713
Absolutely. Here it is:

Unhandled Exception: System.ServiceModel.FaultException`1[[Microsoft.Xrm.Sdk.OrganizationServiceFault, Microsoft.Xrm.Sdk, Version=6.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]: There should be only one owner party for an activityDetail:
<OrganizationServiceFault xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.microsoft.com/xrm/2011/Contracts">
  <ErrorCode>-2147220989</ErrorCode>
  <ErrorDetails xmlns:d2p1="http://schemas.datacontract.org/2004/07/System.Collections.Generic" />
  <Message>There should be only one owner party for an activity</Message>
  <Timestamp>2016-07-29T14:04:08.8346317Z</Timestamp>
  <InnerFault i:nil="true" />
  <TraceText i:nil="true" />
</OrganizationServiceFault>
0
 
LVL 19

Expert Comment

by:Rikin Shah
ID: 41734779
Hi,

Can you confirm if there is any plugin or custom code written on the same entity for update message?

In case, the code exists, check if there is any "AssignRequest" is executed through organizationService object?

AssignRequest should be replaced with update request with "ownerid" field.
0
Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

 

Author Comment

by:IT-Services-TI
ID: 41735103
Hi Rikin,

We do have a plugin running on this entity. It is called Xbitz.Crm.AdvancedCRMAutoNumber and its purpose is to do an autonumbering feature for custom entities. We need to give permissions to the users on this plugin in order for them to create records for most entities, including the Activity entity.

The issue could very well be related to this plugin. How would I go to verify this in the plugin? Do I have to export the plugin solution to my Workstation? If so what do I do from there?

Note that I verified the javascript code running on this entity and it is not causing the issue. To be certain I disabled the javascript code on the form and tried it again and got the same SQL error pop-up.

Let me know.
Thank you!
Stéphane
0
 
LVL 19

Accepted Solution

by:
Rikin Shah earned 500 total points
ID: 41735122
Hi,

You can check the solution components for plugin assemblies and plugin messages.

However, I would suggest you go through code for this plugin and check if there a code for AssignRequest
0
 

Author Closing Comment

by:IT-Services-TI
ID: 41739019
This item priority has lowered after investigating the symptoms more thoroughly. It seems to be affecting only two records at the current time. That being said we won't be working on it for a while so I am closing the thread and I am pretty certain that the solution resides in the suggestion you gave us. Thank you very much for helping!
0

Featured Post

Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

Join & Write a Comment

Suggested Solutions

This is a walkthrough guide I wrote whilst upgrading my on-premise MS Dynamics CRM 3.0 deployment to 4.0. This covers the actual installation of the product to a working level for my system, I ran into a lot of issues that the steps below fixed so h…
Automatically creating a Trello card using data from a Microsoft Dynamics CRM record turned out to be an easy project that yielded great results.  Here's how I did this for an internal team at General Code.
This video discusses moving either the default database or any database to a new volume.
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

708 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now