Get-ADUser -Filter * -SearchBase "dc=YourDomain,dc=com" | select Name, @{l='OU';e={$_.DistinguishedName.split(',')[1].split('=')[1]}}
Notes
# Return users and full distinguished names Get-ADUser -Filter * -SearchBase "dc=YourDomain,dc=com" | select Name, DistinguishedName
tags: MrNetTek