Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Using CSVDE to export User Names and Email Addresses

Status
Not open for further replies.

JCDugas

MIS
Dec 26, 2001
270
0
0
US
I'm wondering if anyone out there knows how to export the User Name and Email Addresses of all of my users in Active Directory using the CSVDE or any other tools.

Thanks,

Jeremy
 
Try

csvde -f output.csv -l "sn, userPrincipalName, mail"
-r "(ObjectClass=User)



Gia Betiu
gia@almondeyes.net
Computer Eng. CNE 4, CNE 5, MCSE Win2K
new: (just started)
 
Cool, that works!

How do I export for a particular OU?

Jeremy
 
You can study this article:


C:\>csvde -f output2.csv -l "userPrincipalName, mail" -r "(ObjectClass=User)" -d "ou=test,dc=cluster, dc=gia"

in case that you have the domain: "cluster.gia" and the OU inside of the cluster domain is "test".

Gia Betiu
gia@almondeyes.net
Computer Eng. CNE 4, CNE 5, MCSE Win2K
new: (just started)
 
My problem is related to this:
When I run this command :

CSVDE -f mstest.csv -r "(&(objectClass=user))" -l "objectClass, displayName, DN, mailNickname, targetAddress, mail"

I also get a bunch of computer accounts showing in the exported file like this:
CN=SA-NAME,CN=Computers,DC=mydomain,DC=co,DC=uk SA-NAME$ computer

I have tried other ObjectClass filters & this does not happen.
Any Ideas?

I have also tried GiaBetiu's suggestion :
csvde -f output.csv -l "sn, userPrincipalName, mail"
-r "(ObjectClass=User)

But still get computer accounts

Any ideas?
Thanks

---------------------------------------
save a life - visit:
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top