Re: LDAP query returns data in parent domain but not from child domain



Howard Bullock wrote:

My query:
select objectSid from 'LDAP://dc=child,dc=company,dc=com' where memberof =
'CN=GatdWillHamatyU,CN=Users,DC=child,DC=company,DC=com'

This format work fine for querying membership of groups in
DC=company,DC=com' where my user account resides.

One thing I suspected was that I needed to tell the query where to bind so
I
modified it to be:
select objectSid from
'LDAP://child.company.com/dc=child,dc=company,dc=com'
where memberof = 'CN=GatdWillHamatyU,CN=Users,DC=child,DC=company,DC=com'.

This also failed. I even used a FQDN of a domain controller in the child
domain.

How should I structure the ADO connection and LDAP SQL dialect query to
list
the full membership of all groups in a child domain? Incidentally my
computer
is currently in the child domain.


Try using GC:// instead of LDAP://. The memberOf attribute is in the global
catalog.

--
Richard Mueller
Microsoft MVP Scripting and ADSI
Hilltop Lab - http://www.rlmueller.net
--


.