Ureader.com  
Microsoft software help and Community
   home   |   control panel login   |   archive   |  
 
Exchange
2000.active.directory
2000.admin
2000.announcements
2000.app.conversion
2000.applications
2000.clients
2000.clustering
2000.connectivity
2000.development
2000.documentation
2000.general
2000.information.store
2000.interop
2000.kms
2000.misc
2000.protocols
2000.realtime.collabo.
2000.setup
2000.transport
2000.win2000
admin
application.conversion
applications
clients
clustering
connectivity
design
development
misc
mobility
setup
tools
  
 
date: 24 Aug 2005 04:47:59 -0700,    group: microsoft.public.exchange2000.active.directory.integration        back       


Advice on how to write an LDAP AD user query   
Hello All

I need to be able to qrite a fairly simple LDAP query in AD to bring
back the following:

All active users (in an OU called users) who don't have an SMTP email
address which starts username@domain for example (the user name is a
number).

Can this be easily be done I use AD 2003 daily and need this
information.


Thanks in Advance
date: 24 Aug 2005 04:47:59 -0700   author:   unknown

Re: Advice on how to write an LDAP AD user query   
You can't base an LDAP query dynamically upon what the object name is being 
checked. You would need to dump all users with smtp addresses and compare the 
username with the address.

    joe

--
Joe Richards Microsoft MVP Windows Server Directory Services
www.joeware.net


slinkydonkey@hotmail.com wrote:
> Hello All
> 
> I need to be able to qrite a fairly simple LDAP query in AD to bring
> back the following:
> 
> All active users (in an OU called users) who don't have an SMTP email
> address which starts username@domain for example (the user name is a
> number).
> 
> Can this be easily be done I use AD 2003 daily and need this
> information.
> 
> 
> Thanks in Advance
>
date: Thu, 25 Aug 2005 20:55:04 -0400   author:   Joe Richards [MVP]

Re: Advice on how to write an LDAP AD user query   
Hi Joe

I finaly managed to write an LDAP query to bring back all email address
that don't end with the SMTP email address @myworksdomain.co.uk.

I didnt understand your reply but thanks anyway. :O)


Joe Richards [MVP] wrote:
> You can't base an LDAP query dynamically upon what the object name is being
> checked. You would need to dump all users with smtp addresses and compare the
> username with the address.
>
>     joe
>
> --
> Joe Richards Microsoft MVP Windows Server Directory Services
> www.joeware.net
>
>
> slinkydonkey@hotmail.com wrote:
> > Hello All
> >
> > I need to be able to qrite a fairly simple LDAP query in AD to bring
> > back the following:
> >
> > All active users (in an OU called users) who don't have an SMTP email
> > address which starts username@domain for example (the user name is a
> > number).
> >
> > Can this be easily be done I use AD 2003 daily and need this
> > information.
> > 
> > 
> > Thanks in Advance
> >
date: 6 Sep 2005 06:11:30 -0700   author:   unknown

Re: Advice on how to write an LDAP AD user query   
That is different from what you asked for. It is much easier.

That query would look something like

(!(mail=*@myworksdomain.co.uk))

or if you wanted to make sure it was users who had a mail attribute but not one 
with the value you specified


(&(objectcategory=person)(objectclass=user)(mail=*)(!(mail=*@myworksdomain.co.uk)))





--
Joe Richards Microsoft MVP Windows Server Directory Services
www.joeware.net


slinkydonkey@hotmail.com wrote:
> Hi Joe
> 
> I finaly managed to write an LDAP query to bring back all email address
> that don't end with the SMTP email address @myworksdomain.co.uk.
> 
> I didnt understand your reply but thanks anyway. :O)
> 
> 
> Joe Richards [MVP] wrote:
> 
>>You can't base an LDAP query dynamically upon what the object name is being
>>checked. You would need to dump all users with smtp addresses and compare the
>>username with the address.
>>
>>    joe
>>
>>--
>>Joe Richards Microsoft MVP Windows Server Directory Services
>>www.joeware.net
>>
>>
>>slinkydonkey@hotmail.com wrote:
>>
>>>Hello All
>>>
>>>I need to be able to qrite a fairly simple LDAP query in AD to bring
>>>back the following:
>>>
>>>All active users (in an OU called users) who don't have an SMTP email
>>>address which starts username@domain for example (the user name is a
>>>number).
>>>
>>>Can this be easily be done I use AD 2003 daily and need this
>>>information.
>>>
>>>
>>>Thanks in Advance
>>>
> 
>
date: Wed, 07 Sep 2005 17:45:32 -0400   author:   Joe Richards [MVP]

Google
 
Web ureader.com


    COPYRIGHT 2007, YARDI TECHNOLOGY LIMITED, ALL RIGHT RESERVE  |   contact us