Hello Matheesha,
 
if you want to check if it is indexed you have to check if bit 1 of the searchFlags Attribute is set.
 
You can do this using an LDAP-Query like
 
(&(objectCategory=attributeSchema)(searchFlags:1.2.840.113556.1.4.803:=1))
 
Using dsquery this would be
dsquery * cn=schema,cn=configuration,dc=example,dc=com -filter "(&(objectCategory=attributeSchema)(searchFlags:1.2.840.113556.1.4.803:=1))" -attr name
 
If you want to set the index, verify that searchFlags AND 1 = 0, then add 1 to seachFlags.
 

Gruesse - Sincerely,

Ulf B. Simon-Weidner

  MVP-Book "Windows XP - Die Expertentipps": http://tinyurl.com/44zcz
  Weblog: http://msmvps.org/UlfBSimonWeidner

  Website:
http://www.windowsserverfaq.org
  Profile:   http://mvp.support.microsoft.com/profile=""> 
  

 


From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Matheesha Weerasinghe
Sent: Tuesday, April 18, 2006 8:14 PM
To: [email protected]
Subject: Re: [ActiveDir] stupid ldap queries

sorry that was meant to be adfind -schema -f "&(objectclass=attributeschema)(ismemberofpartialattributeset=T RUE)" ldapdisplayname -list

On 4/18/06, Matheesha Weerasinghe <[EMAIL PROTECTED]> wrote:
Thanks for the reply. In that case why does

adfind -schema -f "&(objectclass=attributeschema)(ismemberofpartialattributeset=T RUE)" ldapdisplayname -list

returning objectclass amongs the others? Doesn't this mean objectclass is indexed? The reason I ask is because I wanted to make sure I didn't write stupid ldap queries that load up the server. I am still learning so please be patient with this n00b.

Thanks

M@


On 4/18/06, Brian Desmond < [EMAIL PROTECTED]> wrote:
> Not sure I understand the question fully, but, no objectClass is not
> indexed. objectCategory is. So if you want to get all users you do:
>
> (&(objectCategory=person)(objectClass=user))
>
> Thanks,
> Brian Desmond
> [EMAIL PROTECTED]
>
> c - 312.731.3132
>
>
>
> > -----Original Message-----
> > From: [EMAIL PROTECTED] [mailto:ActiveDir-
> > [EMAIL PROTECTED]] On Behalf Of Matheesha Weerasinghe
> > Sent: Tuesday, April 18, 2006 1:00 PM
> > To: [email protected]
> > Subject: [ActiveDir] stupid ldap queries
> >
> > All
> >
> > Could someone please explain how Non-indexed queries (e.g.
> > "objectClass=user") fall in this category? I saw this mentioned in
> some
> > slides by Gil and couldnt quite understand what he meant. Isn't
> > objectclass indexed as part of the partial attribute set?
> >
> > Thanks
> >
> > M@
> > List info   : http://www.activedir.org/List.aspx
> > List FAQ    : http://www.activedir.org/ListFAQ.aspx
> > List archive: http://www.mail-
> > archive.com/activedir%40mail.activedir.org/
> List info   : http://www.activedir.org/List.aspx
> List FAQ    : http://www.activedir.org/ListFAQ.aspx
> List archive: http://www.mail-archive.com/activedir%40mail.activedir.org/
>

Reply via email to