Solution With Id = 86ac16ec-41d7-4685-a330-0b1c31411260 Does Not Exist

In some rare scenario's you might get the error message "solution With Id = 86ac16ec-41d7-4685-a330-0b1c31411260 Does Not Exist" while deleting a solution. In our scenario this seems to happen after using the holding solution approach. Luckily this can be solved as long as you have access to the SQL database. Note: Direct SQL updates are unsupported, so only perform this action if you're aware of the risks.

The error appears due to some remaining AttributeMap records for virtual attributes. In more detail, when you create an attribute map between two entities for a lookup attribute, it not only creating an attribute map for the id of the entity, but also for the name of that particular lookup. So in case of an account mapping, it creates an attribute map for accountid as well as accountidname. After moving around with solutions, CRM occacionally forgets to update the owning solution id for the 'name' attribute mappings.

You can visualize the relevant attributes using the following query:

SELECT
 a.SolutionId,
 a.SourceAttributeName,
 a.TargetAttributeName,
 pa.SolutionId,
 pa.SourceAttributeName,
 pa.TargetAttributeName
FROM attributemapbase a
LEFT OUTER JOIN attributemapbase pa
 ON a.parentattributemapid=pa.attributemapid
WHERE a.solutionid='86ac16ec-41d7-4685-a330-0b1c31411260'

You'll see the virtual attributes with their parent attributes and the corresponding solutionid according to the attribute map. The mismatch between the solutionid of the attributemap and the solutionid of the parent attribute map is what causes the error while deleting the solution. Updating the solutionid will solve the issue for you. Here's the query to help you perform this action. Obviously you'll need to change the solutionid to the solutionid as presented to you when downloading the error log file:

UPDATE AttributeMapBase
 SET SolutionId = pa.solutionid
 FROM AttributeMapBase
LEFT OUTER JOIN AttributeMapBase AS pa
 ON AttributeMapBase.ParentAttributeMapId = pa.AttributeMapId
WHERE AttributeMapBase.SolutionId = '86ac16ec-41d7-4685-a330-0b1c31411260'

I'm sure Microsoft will fix this issue sooner or later, but for now I hope this post will help you anyway.


Update:
Apparently there are other scenario's when this error occurs as well. When you create a businessrule, then on the database a record will be created in the "WorkflowBase" will be created, as well as one or more records in the "ProcessTriggerBase". For some reason it is possible that the records in the ProcessTriggerBase are not updated to the new solution ID, resulting in an incorrect record. While deleting a managed solution the deletion process recorgnized the non existing SolutionID and causes the delete to stop.

The way to identify the business rule that is causing the issue, you can run the following query:

select ptb.ProcessId, wb.Name, ptb.solutionid, wb.solutionid
from
 
 
ProcessTriggerBase ptb
 
left join WorkflowBase wb on ptb.ProcessId = wb.WorkflowId
where
ptb.solutionid='86ac16ec-41d7-4685-a330-0b1c31411260'

You then can delete this business rule by hand using the advanced find (search for all processes with category=business rule). Once this rule is removed, then the solution can be uninstalled.

17 comments:

Hans Nellestijn said...

Hi Ronald,

Thanks, you made my day!
We regularly use the "holding solution approach" and I regularly got this error-message. Again, your blog is the only one found with a real solution to this.

Ronald Lemmen said...

Much appreciated Hans!

ax dynamics said...

Hello! Thank you for sharing this, I had no Idea how to remove the message and fix this error. Thanks for help, I’m a beginner in erp software sphere, but I’m trying to do my best and learn some new features.

Packers and movers bangalore said...

Packers-and-movers-bangalore.in provides all the type of #moving solutions, no matter where you want to shift into the city or shift another city or another country ..
Packers And Movers Bangalore Charges

Packers Movers Gurgaon said...

Really impressive post. I read it whole and going to share it with my social circules. I enjoyed your article and planning to rewrite it on my own blog.
Packers And Movers Gurgaon
Packers And Movers In Gurgaon charges

Packers Movers Gurgaon said...

We Provide Best Packers And Movers Gurgaon List for Get Free Best Quotes, Compare Charges,
Save Money And Time, Household Shifting Services @ http://packers-and-movers-gurgaon.in/
Packers And Movers Bangalore to hyderabad

Packers And Movers Bangalore said...

I must say you had done a tremendous job,I appreciate all your efforts.Thanks alot for your writings......Waiting for a new 1...Please visit our wonderful and valuable website-
Packers And Movers Bangalore

Packers And Movers Bangalore said...

Packers And Movers Indiranagar Bangalore



Packers And Movers Electronics City bengaluru

Packers And Movers Marathahalli Colony bengaluru

Packers And Movers whitefield Bangalore

Packers And Movers Hsr Layout bengaluru

packers and movers hyderabad said...

Thanks on your marvelous posting! I really enjoyed reading it, you’re a great author.Please visit here:
Packers And Movers Hyderabad

rahul sharma said...


packers and movers pune
packers and movers indore
packers and movers gurgaon

James R said...

Hi, Ronald - I know this is an old blog but have you ever had this issue with a web resource?

Packers And Movers Jaipur said...

Brilliant information being shared here with us,This is very interesting, You’re a very skilled blogger.Plz visit here: Packers And Movers Jaipur

Packers And Movers Jaipur said...

Packers And Movers Jaisalmer
Packers And Movers Jodhpur
Packers And Movers Udaipur
Packers And Movers Abu Road
Packers And Movers Banswara
Packers And Movers Barmer
Packers And Movers Bundi
Packers And Movers Chomu

Packers And Movers Jaipur said...

Packers And Movers Jaipur to Mumbai
Packers And Movers Jaipur to Haridwar
Packers And Movers Jaipur to Noida
Packers And Movers Jaipur to Leh
Packers And Movers Jaipur to Guntur
Packers And Movers Jaipur to Muzaffarpur
Packers And Movers Jaipur to Indore
Packers And Movers Jaipur to Surat

packers and movers chennai said...

An excellent information provided thanks for all the information i must say great efforts made by you. thanks a lot for all the information you provided.
Packers And Movers Chennai

packers and movers chennai said...

Packers And Movers Chennai to Jaipur
Packers And Movers Chennai to Mumbai
Packers And Movers Chennai to Delhi
Packers And Movers Chennai to Gurgaon
Packers And Movers Chennai to Kolkata
Packers And Movers Chennai to Bhubaneswar
Packers And Movers Chennai to Bhopal
Packers And Movers Chennai to Lucknow
Packers And Movers Chennai to Chandigarh

packers and movers chennai said...

Packers And Movers Kanyakumari Tamilnadu
Packers And Movers Karur Tamilnadu
Packers And Movers Krishnagiri Tamilnadu
Packers And Movers Madurai Tamilnadu
Packers And Movers Nagapattinam Tamilnadu
Packers And Movers Namakkal Tamilnadu
Packers And Movers Nilgiris Tamilnadu
Packers And Movers Perambalur Tamilnadu
Packers And Movers Pudukkottai Tamilnadu
Packers And Movers Ramanathapuram Tamilnadu