Find Users without a Manager in Active Directory

  • September 29, 2017
  •  
  • November 25, 2018
Get-ADUser -SearchBase "ou=users,dc=contoso,dc=com" -Filter * -Properties Name, EmployeeNumber, UserPrincipalName, Manager | where {$_.Manager -eq $null} | ft Name, EmployeeNumber, UserPrincipalName, Manager

Because “Manager” being an extended attribute in Active Directory you can’t use -Filter {Manager -notlike “*“} like you would with basic attributes