August 13th, 2012

PowerTip: Querying Active Directory via PowerShell

Doctor Scripto
Scripter

Summary: Learn how to query Active Directory via Windows PowerShell.

Hey, Scripting Guy! Question Can you name five ways to query Active Directory from within Windows PowerShell?

Hey, Scripting Guy! Answer

  1. Use ADO and perform an LDAP dialect query.
  2. Use ADO and perform an SQL dialect query.
  3. Use the Get-ADObject cmdlet from the Active Directory module.
  4. Use DSQuery.
  5. Use the [ADSISearcher] type accelerator.

Author

The "Scripting Guys" is a historical title passed from scripter to scripter. The current revision has morphed into our good friend Doctor Scripto who has been with us since the very beginning.

0 comments

Discussion are closed.