Question
July 22, 2007 at 12:14 PM
cantrejj

SQL syntax for querying AD group membership

by cantrejj . Updated 19 years, 3 months ago

I’ve established a connection to Active Directory through Crystal Reports. Now I need to write an SQL select statement to return all computer accounts and their group memberships. My statement returns all the computer accounts in the target OU, but the MemberOf field is empty. I’ve included below my query statement and would welcome any suggestions…
*******************************************
Select CN, memberOf
From ‘LDAP://OU=Managed Accounts, OU=Central Valley Service Area, DC= root, DC=sutterhealth, DC=org’
where ObjectClass=’computer’
*********************************************

This discussion is locked

All Comments