Wow … thousands … really? So my recommendation would be to fire most of them. You actually need more people doing something … not just managers.

But the fact that you have a big amount of uniform objects to process shouldn’t scare you. You have a computer to do the boring and repetitive work for you. 
I’ll leave it to you how to query your AD for those thousands of managers. Here’s an example of how to query an OU for user accounts and turn the output into a hashtable you can use later on.
$SearchBase = 'OU=manager,OU=people,DC=contoso,DC=com'
$ManagerHashtable =
Get-ADUser -SearchBase $SearchBase -Filter * -Properties DisplayName, EmployeeID |
ForEach-Object {
@{
$_.DistinguishedName = @{
DisplayName = $_.DisplayName
sAMAccountName = $_.sAMAccountName
EmployeeID = $_.EmployeeID
}
}
}
Now the rest is actually a piece of cake … I borrowed Robs code (sorry Rob
) and tweaked it to include the output of the managers EmployeeID, DisplayName and sAMAccountName.
$adGroupList = 'BI_FINANCE_FULL', 'BI_FIN_EXP_FACILITIES_FULL_R1'
$results =
foreach ($group in $adGroupList) {
Get-ADGroupMember -identity $group -Recursive |
Get-ADUser -Properties DisplayName, EmployeeID, Departement, Title, physicalDeliveryOfficeName, Manager |
Select-Object @{Name = 'Group'; Expression = { $group } },
displayname,
name,
sAMAccountName,
givenName,
surname,
UserPrincipalName,
employeeID,
Department,
title,
physicalDeliveryOfficeName,
@{Name = 'ManagerDisplayName'; Expression = { $ManagerHashtable.$($_.Manager).DisplayName } },
@{Name = 'ManagerSamaccontName'; Expression = { $ManagerHashtable.$($_.Manager).sAMAccountName } },
@{Name = 'ManagerEmployeeID'; Expression = { $ManagerHashtable.$($_.Manager).EmployeeID } }
}
$results | Export-Csv -Append 'C:\temp\GetADGroupMember4.csv' -NoTypeInformation -Encoding UTF8
… it’s untested … the environment I have available to test doesn’t even have managers set up in the user accounts … sorry.
If the aaproach with the hashtable does not work for you for any reason you could still use a simple list of objects queried from the AD and saved to a variable instead of querying the AD for each and every single member of one of your groups again and again and again. Even that should speed up your code remarkably.