running this query only gets me 1 name in the table 2.txt and 1.txt table has about 20 usrs -- how could I have it include all names in 1.txt
Unless there's another way, I need to know all the user names and full names in a specific groupname...
echo Processing DSQUERY to obtain MEMBER names....
dsquery group DC=hospitals,DC=local -name HspGroupName %1 | dsget group -members > c:\temp
echo DSQUERY MEMBERS -- DONE!
echo Processing DSQUERY to obtain account names....
for /F "tokens=*" %%A in (c:\temp\1.txt) do dsquery * %%A -attr sAMAccountName name > c:\temp\2.txt