Экспорт данных из Powershell в CSV

как добавить вывод данных о компьютерах в файл CSV?

Import-CSV -Path D:\asd.csv | ForEach { Get-ADComputer -identity $_.computer -properties extensionAttribute1, created, Description, enabled  | select extensionAttribute1, created, Description, enabled }

Так не работает:

Import-CSV -Path D:\asd.csv | ForEach { Get-ADComputer -identity $_.computer -properties extensionAttribute1, created, Description, enabled  | select extensionAttribute1, created, Description, enabled | export-csv -path D:\dsa.csv}
Import-CSV -Path D:\asd.csv | ForEach { Get-ADComputer -identity $_.computer -properties extensionAttribute1, created, Description, enabled  | select extensionAttribute1, created, Description, enabled } | export-csv -path D:\dsa.csv

Ответы (0 шт):