We were getting this error when creating a new record in CRM 2011 using REST SDK. The new record entity has a post-create plugin that updates a field.
var entity = (Entity)context.InputParameters["Target"]; var mappedEntity = entity.ToEntity<incident>(); mappedEntity.new_x = "abc"; localContext.OrganizationService.Update(mappedEntity);
This error was caused by update transaction which needs to be executed on a different context. Since the plugin context has finished executing create on the entity (EntityState = “Created”), CRM is preventing the update transaction to be completed.
The workaround would be doing the update on Pre-Operation stage, or retrieving the entity and update the retrieved entity instead of the entity in plugin context’s InputParameters.
Cheers – Sy