Link to home
Start Free TrialLog in
Avatar of techdrive
techdriveFlag for United States of America

asked on

Powershell Exchange 2013 Batch question

I work in a very large enterprise environment and we are moving users to Exchange 2013. The one issue that we need to automate is placing the primarysmtpaddress in a text file with the header emailaddress. What we have done is taken a large mass of users maybe 1,000 at a time and save them to different csv files with the header emailaddress. In the CSV file/excel we sort by name and create a column called batch. In there we place numbers 1-30 and keep starting over from 1-30 until we get to the 1,000th person. We then sort on that field and everything with 1 goes into a file with emailaddress as the header and populate this with just the primarysmtpaddress.We do this for everything that has a number 2, place this in a csv file with the header emailaddress with the primarysmtpaddress. We keep going on and on and on until we reach 30th which has the 1000 user. As you can see this is painful and long.  How can you get powershell to look inside of a csv file, grab all the number 1's place them into a separate csv file with the header emailaddress and move on until it gets to 30.  If someone has a better method please do share
ASKER CERTIFIED SOLUTION
Avatar of SubSun
SubSun
Flag of India image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of techdrive

ASKER

Perfect thanks