Issue after update MS CRM 2011 rollup 12/13


Microsoft Dynamics CRM 2011: Error after applying Update Rollup 12/13

I haven’t updated my VM to latest updates for a long time and I decided to do that today.
After Rollup was installed I saw message that Rollup was not applied to one or several organizations.
 I ignored that message and tried to log in to CRM. I have got following error:

Rollup issue: A duplicate value cannot be inserted into a unique index.

Hello!

On the week I faced with problem when MS CRM client can`t connect into CRM SERVER. This issue you can found on the 11, 12 and 13 Rollups.

Error log message looked like that:

Error| Exception : A duplicate value cannot be inserted into a unique index. [ Table name = MetadataSchema.EntityClientStatistics,Constraint name = PK__MetadataSchema.EntityClientStatistics__000000000000071C ]    at System.Data.SqlServerCe.SqlCeCommand.ProcessResults(Int32 hr)
   at System.Data.SqlServerCe.SqlCeCommand.ExecuteCommandText(IntPtr& pCursor, Boolean& isBaseTableCursor)