Some people asked for a little script/command, to search for all groups on a specific OU and put some info info in "Managed By" attribute (the LDAP name of a App OIM Server )
I´m not particulary interest in search for NULL/Blank "Managed By" Attributes, because even if there is some group already with the information, it not will be a problem to "re-write" the information again.
I could get the requeired groups with no problem:
Get-ADgroup -Filter {Name -ne "99"} -SearchBase "OU=-Rio,DC=company,DC=com" -properties * | ft name,ManagedBy
Now i need to do a set-ADuSER to put a specific string, but in some situations, the attribute is known as "Manager" and other ones, as "ManageBy"