Contact Info

Crumbtrail

ActiveXperts.com » Administration » Powershell » Powershell 3.0 » Compare-Object

Compare-Object - Powershell 3.0 CmdLet

ActiveXperts Network Monitor ships with integrated Powershell scripts to monitor complex network. The scripts run out of the box
Download the ActiveXperts Network Monitor FREE version now »

Compare-Object

Short description
Compares two sets of objects.

Syntax


Description
The Compare-Object cmdlet compares two sets of objects. One set of objects is the "reference set," and the other set is
 the "difference set."


The result of the comparison indicates whether a property value appeared only in the object from the reference set (ind
icated by the <= symbol), only in the object from the difference set (indicated by the => symbol) or, if the IncludeEqu
al parameter is specified, in both objects (indicated by the == symbol).


NOTE:  If the reference set or the difference set is null ($null), Compare-Object generates a terminating error.