Introduction:
After installing SP1 on existing CRM 2013 on-premise server, we need to enable the customer service enhancement features for each Org from Settings –>Administration –> Install Product Updates as shown in below screenshot:
Once enabled, the Update can’t be uninstalled.
What if you want to create an Org without the Product Updates installed on CRM 2013 SP1?
Once you install SP1 on CRM 2013 Server, then every org you create after that will have the product updates already installed and enabled by default and you do not need to manually install the product update.
If you want to create Org with no service enhancement enabled on CRM 2013 SP1 Server, then you need to run below power shell script before you create the Organization:
add-pssnapin Microsoft.Crm.Powershell
$itemSetting = new-object ‘System.Collections.Generic.KeyValuePair[String,Object]'(“OptinProvisioningEnabled”,0)
$configEntity = New-Object “Microsoft.Xrm.Sdk.Deployment.ConfigurationEntity”
$configEntity.LogicalName=”Deployment”
$configEntity.Attributes = New-Object “Microsoft.Xrm.Sdk.Deployment.AttributeCollection”
$configEntity.Attributes.Add($itemSetting)
Set-CrmAdvancedSetting -Entity $configEntity
After running power shell scripts, create the Org and you will find the same screen as given above which will ask you to manually install the product updates.
By executing this power shell command, we change the OptinProvisioningEnabled column value to O.
To again set default behavior, run the same script and simply replace O with 1 as “(“OptinProvisioningEnabled”, 1)”
You can also check the value for the same “OptinProvisioningEnabled” in the SQL Database that the Bit column is set to 1 after you install SP1 on CRM 2013 On-Premise.
If you want to check programmatically whether the product updates for customer service enhancements are enabled or not, then you can check in MS CRM 2013 SDK. We have given an example using OData query as below.
Organization URL/XRMServices/2011/OrganizationData.svc/SolutionSet?$select=UniqueName&$filter=UniqueName eq ‘ServiceEnhancements610’
After running above query, if the record with ‘unique name’=”ServiceEnhancements610” is returned then the respective Org has the service enhancements enabled. We have executed this ODATA query which returned below results as shown in screenshot:
Using the same query, the Org with no Service enhancement enabled will return the below result:
The “ServiceEnhancements610” solution is installed internally when the product updates are enabled and this solution is not visible in the Solutions Area Grid interface.
Conclusion:
As this update is installed as solution component, we tried deleting/uninstalling this solution programmatically using below query:
QueryExpression queryImportedSolution = new QueryExpression
{
EntityName = “solution”,
ColumnSet = new ColumnSet (newstring[] { “solutionid”, “friendlyname” }),
Criteria = new FilterExpression()
};
queryImportedSolution.Criteria.AddCondition(“uniquename”, ConditionOperator.Equal, “ServiceEnhancements610”);
Entity ImportedSolution = (Entity)_serviceProxy.RetrieveMultiple(queryImportedSolution).Entities[0];
_service.Delete(ImportedSolution.LogicalName, ImportedSolution.Id);
But, the request terminated with error “Attempting to delete a restricted solution” as shown in below screenshot:
So once the Service Enhancements updates are installed on an Org there is no rollback option available.