SELECT SAMAccountName, displayName, telephoneNumber, mobile, title, givenName, sn, mail, initials, l, userAccountControl
FROM OPENQUERY(ADSI,
'SELECT userAccountControl, l, initials, mail, sn, givenName, title, mobile, telephoneNumber, displayName ,SAMAccountName
FROM ''LDAP:///OU=USer,DC=domainDC=local,'' WHERE objectClass=''user'' AND objectCategory=''person'' and memberof=''CN=Equity Partners,OU=group DC=domain,DC=local'' ')
AS derivedtbl_1
WHERE (displayName IS NOT NULL) AND (givenName IS NOT NULL) AND (l IS NOT NULL) AND (LEN(SAMAccountName) <= 3)
The query above give me the information for one group except need to add group name to display.
Regards
Craig