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 Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Pass the output of dsquery command to another instance of dsquery cmd

Status
Not open for further replies.

davego33

MIS
Apr 20, 2001
1
US
I want to pass the output of this dsquery cmd:

dsquery user -samid SomeUser

output is:
"CN=SomeUser,OU=Users,OU=ThisCompany,DC=MYDOM,DC=com"[/color red]

to another instance of the dsquery command:
dsquery * "CN=SomeUser,OU=Users,OU=ThisCompany,DC=MYDOM,DC=com"[/color red] -scope base -attr *

Each of these commands works correctly from my command line; however, I can't seem to figure out how to pass the output of the first to the second so the second instance can output the info for that specific AD user.

Thanks for any help
Dave
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top