Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Extract data from active directory array


I have recently connected Crystal Reports XI to Active Directory 2003. I am able to pull back a user's data like sAMAccountName, department etc.

However I am unable to pull back the groups that a user is assigned to. I am thinking this might be because they have multiple groups assigned to them?

Here is the code i am using to select and return the data for name etc:

SELECT name,company,department,samaccountname,mail,manager, mobile, memberof

FROM 'LDAP://OU=Interne,OU=Users,OU=Orkla Finans,DC=finans,DC=orkla,DC=net'

How would one return a user's groups that they are assigned to? I have tried entering the memberOf field in my code, but this returns empty. It seems like Crystal is returning the memberOF field as a string while it is stored as an array in Active Directory.

Former Member
Not what you were looking for? View more on this topic or Ask a question