PS: There are other ways to access that information within a string, such as assigning the value directly to a variable or using the format operator. Display friendly file sizes in PowerShell At one of my recent classes, while discussing hashtables and calculated properties I showed an example of how to list the file’s size in kilobytes instead of the default bytes size. Select-Object accepts the same property parameters but keeps the objects, so by adding that BEFORE you export, all should be fine. Use Sort-Object before using Format-Custom to group the objects. Format-Table will not do you any good because you apply it AFTER you exported, and also Format-Table will change objects to formatting objects that you no longer can export. You can also refer to Format-Wide by its built-in alias, fw. But, we’ll save that for … Ever want to pull in an extra property with the Select-Object command in PowerShell but the property doesn't exist or isn't in the format you need. Note 2: For this particular job I prefer to use Format-Table because I can achieve the same result and in addition employ -auto to tighten up the columns. They can in a way be related to a join in SQL. Get-Process | Format-Table @{label='CPU Time';Expression={$_.Cpu}}, @{Label='Process Name'; Expression ={$_.ProcessName}} When trying to pipe this script to the Out-GridView cmdlet, an error is received because of the type of object that format cmdlets produce. The GroupBy parameter assumes that the objects are sorted. For more information, see about_Aliases. Format-Wide returns format objects that represent the table. That is where the Select-Object expressions come into play. Microsoft.PowerShell.Commands.Internal.Format. Note 1: You can shorten Select-Object to plain ‘Select’, this is because PowerShell has an alias of that name. Notes. PowerShell: Working With Regular Expressions (regex) Link to Parent: PowerShell - Deep Dive and Best Practice There are several different ways to work with regular expressions in PowerShell and this wiki will go over some of these different methods. PowerShell Select-Object by Value Prateek Singh , 3 years ago 7 2 min read 6603 If you are reading this you must have used PowerShell Select-object in PowerShell to select …