header image

Just enough

Posted by: | July 23, 2011 | No Comment |

One thing that never seems to stated is that you don’t need to use the full criteria when searching for something. As an example I wanted to know the COM related services running on a system

Get-Service | where {$_.DisplayName -like "*com*"}


Status   Name               DisplayName
——   —-               ———–
Running  Browser            Computer Browser
Stopped  COMSysApp          COM+ System Application
Running  DcomLaunch         DCOM Server Process Launcher
Running  EventSystem        COM+ Event System
Running  PcaSvc             Program Compatibility Assistant Ser…

which is exactly what I wanted.

Start vague and narrow down rather spending a lot of time trying to refine the criteria up front.  I’ve found its a faster way to get to the results

under: PowerShell Basics