Created
September 5, 2015 16:21
-
-
Save Dan1el42/12efb2c39b4aa1eef8c7 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Import-Csv -Path '.\Input.csv' | | |
Select-Object -Property MACHINENAME, @{Name='OSVERSION'; Expression={ Get-WmiObject -Class Win32_OperatingSystem -Property Caption -ComputerName $_.MACHINENAME -ErrorAction SilentlyContinue | Select-Object -ExpandProperty Caption }} | | |
Export-Csv -Path '.\Output.csv' -NoTypeInformation |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment