I am using a simple line of PS to pull a list of users display names and their employee ID's, along with an expression to get their managers display names. Is there an easy way to modify the expression to pull the manager's name AND manager's employee ID? We use ExtensionAttribute10 for the employee id.
My PS is
Get-ADUser -SearchBase "OU=blah - Internal,DC=blah-corp,DC=com" -filter * -properties * | select DisplayName,ExtensionAttribute10,@{Name='Manager';Expression={(Get-ADUser $_.Manager).name }}Can I create a second expression in that line or am I on the wrong track