Anyone with the proper permissions tried unsuccessfully to delete the collection in the console Configuration Manager's (or using PowerShell commands) must have experienced quite a surprise. After all, when working within the console, we do not always receive a message preceding the successful deletion of a collection:
The familiar message shown before deleting a collection may not ultimately lead to the destination. Below is the message shown when in the command Remove-CMCollection There will be no -Force option:
It behaves particularly strangely in such a "case of impossibility" PowerShell command, which shows errors with a description:
Description = "Unable to update collection due to SQL error."
What are the conditions so that, having sufficient permissions, it is not possible to delete the collection? One can risk the hypothesis that it is references to other objects that cause such a phenomenon. To test this, a number of collections with different types of object references were prepared.
Testing the deletion of the collection, the following results were obtained:
So, as you can see, deleting collections is prevented when references to a collection occur in other objects that would lose their meaning without it. For example, the "Deployment" of an application, but also a sequence of tasks or a program belonging to a distribution package, makes no sense without a collection (it would not be able to be created without pointing to a collection!).
They do not stop deletion when other objects are referenced in the collection (e.g., membership rules, service windows, variables, refresh schedule).