Saturday, June 13, 2020

Dynamics CE Tricks – Remove SLA from entity in CRM solution

There are few entity attributes which can enabled by solution but cannot disabled. Removing such properties not natively supported by Microsoft.
Those properties are,
    Feedback, Activities, Connections, Queues, Enable for SLA


Some of attributes may create new fields (most of time relationships) after enable (like SLA). If anyone accidently enabled one of those property there is no way to removed. There is an unsupported way to remove those properties.

However please try following steps with trial environment first and test before applying to any other environment.

Today we are going to remove SLA property from solution.
After enable SLA it creates two relationships and two fields between current entity and SLA related entities. First you have to export unmanaged solution. Also backup your environment using power platform before perform any change. In case you can restore backup instance.
Unzip your unmanaged solution first and open customization.xml file using xml support text editor.


Navigate to the relevant entity definition and set SLA flag value to 0


As mentioned in earlier enabling SLA will add few relationships and fields to the entity definition. We have to identify those fields and relationships and remove them. Open solution from CE and find extra fields and relationships
In our case we found two relationships added to our custom entity.
1.    manualsla_demo_tabs
2.    sla_demo_tabs


Remove them from customization.xml



Also there are 2 attributes. We also have to remove them from customization.xml as well.
1.    Slaid
2.    Slainvokeid





Before you pack your solution check it contains any missing dependency in solution.xml. If it has any please remove them from both solution.xml and customization.xml.

Once you completed previous stems you can select all components and zip. Renamed zip file with solution name you downloaded.


Note: Do not compress folder, it won’t import as solution.

Once you completed solution modification then tested it in trial environment before importing to any environment. If it functioning successfully you can import to any environment. To modify existing environment you have to backup all relevant entity data and delete entity. Or you can reset environment and import solution.


No comments:

Post a Comment