header1   header
header
header Register : : Login header
header
connector   connector
menuleft menuright
submenu   submenu
left
Seach by e-mail address across 2 domains...
Last Post 11 Aug 2010 06:51 AM by Mihail Stacanov. 1 Replies.
Printer Friendly
  •  
  •  
  •  
  •  
  •  
Sort:
PrevPrev NextNext
You are not authorized to post a reply.
Author Messages
Fred BueckerUser is Offline
New Member
New Member
Posts:1
Avatar

--
27 Jul 2010 05:08 AM
    I am very new to Powershell and am trying to step up my scripting past batch files... My need is to read a CSV file with a list of e-mail addresses and employee ID's that is outputted from our HR system. I then need to search our primary domain for the e-mail and, if found, update the EmployeeID field of AD. If the e-mail is not found in the primary domain I need to search our sub-domain for the address and update the AD account if it is located there. Both domains are children... primary.company.com and branch.company.com I actually have this "almost" working via batch file, but I am failing on my error handling from my DSQUERY command so I therefore fail to get it to jump domains. I figure this is a perfect way to start using PS and get away from .bat's Thank you for any assistance! (I have installed the Quest AD pack if that will help make any of this easier)
    Mihail StacanovUser is Offline
    New Member
    New Member
    Posts:15
    Avatar

    --
    11 Aug 2010 06:51 AM
    #Just one string if you have Quest AD CmdLets
    Import-Csv d:\email.csv | foreach {Set-QADUser $_.logonname -Email $_.email -WhatIf}
    http://proproit.com
    You are not authorized to post a reply.


    Active Forums 4.3
    right
    footer   footer
    footer Sponsored by Quest Software • SAPIEN Technologies • Compellent • Microsoft Windows Server 2008 R2 footer
    footer   footer