Quick Tip – Get Unique Instances In PowerShell
To remove duplicates using PowerShell is exceedingly straightfroward. However, I have a habit of forgetting the cmdlet so parking this here for future reference.
For example, we can use the Get-Unique cmdlet or Select-Object -Unique parameter.
Get-Unique
As a simple example:
The Get-Unique cmdlet compares each item in a sorted list to the next item, eliminates duplicates, and returns only… Read the rest “Quick Tip – Get Unique Instances In PowerShell”