Prev | Current Page 51 | Next

Joezer Cookey-Gam, Brendan Keane, Jeffrey Rosen, and Jonathan Runyon

"Professional Windows PowerShell for Exchange Server 2007 Service Pack 1"

If the property data type is
integer, a numeric value must be used for the test and so on.
While Windows PowerShell validates the syntax used inside the script block, the result of entering an
unknown property name or an invalid data type is a failure to pass any objects down the pipeline
without reporting any error to the operator.
Multiple test conditions can be used in the same script block as long as they are separated by one or
more conjunctive or disjunctive operators:
The and conjunction operator is used to compare the Boolean results of two or more test conditions
to render a concluding Boolean value. If any of the test conditions are true, a true is
returned.
The or disjunctive operator is used to compare the Boolean results of only two test conditions. If
either one or both test conditions are false, a false is returned.
Conjunctive and disjunctive groups of test conditions can be used in the same script block as
long as they are enclosed in parentheses.
Now let ??™ s look at a practical example of using Where-Object as a filter in the pipeline stream. Say that
you need to change the Manager property for several users based on the department to which they
belong (Engineering), and the office from which they work (the Dallas office) to show they report to
manager John Doe.


Pages:
39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63
online loans for bad credit rating aurora amefa tanie noclegi w polsce producent sal zabaw Władysławowo wakacje