{"id":12918,"date":"2020-07-22T06:35:13","date_gmt":"2020-07-22T06:35:13","guid":{"rendered":"https:\/\/www.testpreptraining.com\/tutorial\/?page_id=12918"},"modified":"2022-03-07T04:14:37","modified_gmt":"2022-03-07T04:14:37","slug":"bulk-user-updates-in-active-directory","status":"publish","type":"page","link":"https:\/\/www.testpreptraining.ai\/tutorial\/bulk-user-updates-in-active-directory\/","title":{"rendered":"Bulk user Updates in Active Directory"},"content":{"rendered":"\n<p class=\"has-text-align-right\"><strong><a href=\"https:\/\/www.testpreptraining.ai\/tutorial\/exam-az-104-microsoft-azure-administrator-associate\/\" target=\"_blank\" rel=\"noreferrer noopener\">Return to AZ-104 Tutorial Page<\/a><\/strong><\/p>\n\n\n\n<p>We shall now learn the process for bulk user updates in Active Directory. This is where automation plays a key role in making the tedious and the long-winded&nbsp;extremely easy. Let us suppose&nbsp;you have a huge data dump of user names with email addresses and phone numbers to be updated in Active Directory. The data dump is given to you in CSV file.<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter\"><a href=\"https:\/\/www.testpreptraining.ai\/microsoft-azure-administrator-associate-az-104-free-practice-test\" target=\"_blank\" rel=\"noopener noreferrer\"><img decoding=\"async\" src=\"https:\/\/www.testpreptraining.ai\/tutorial\/wp-content\/uploads\/2020\/06\/practice-test-2.png\" alt=\"Practice Test for AZ-104\"\/><\/a><\/figure><\/div>\n\n\n\n<p> At present, the&nbsp;users from the dump&nbsp;do not have those values set in Active Directory. We use the following steps to perform the bulk user updates &#8211;<\/p>\n\n\n\n<ol class=\"wp-block-list\"><li>First, use the Import-CSV cmdlet to read in the contents of the dump file.<\/li><li>Second step ForEach-Object cmdlet will execute the code between the curly braces for each line from the CSV file sent down the pipeline.<\/li><li>Next, the code uses Get-ADUser with a filter to matche the &#8216;Name&#8217; from the CSV file column to the name of a user in Active Directory.<\/li><li>Then, if a match is found, then the final object is piped into the Set-ADUser cmdlet. <\/li><li>Lastly, the Set-ADUser cmdlet updated the user&#8217;s email address and phone number based on the current entries from the &#8216;Email&#8217; and &#8216;Phone&#8217; columns of the CSV file.<\/li><\/ol>\n\n\n\n<p>We us use PowerShell to read in the CSV file and make the bulk update (Import-CSV .\\Data_Update.csv |)<\/p>\n\n\n\n<p>ForEach-Object {Get-ADUser -Filter &#8220;Name -eq `&#8221;$($_.Name)`&#8221;&#8221; | Set-ADUser -EmailAddress $_.Email -OfficePhone $_.Phone}<\/p>\n\n\n\n<div class=\"wp-block-image\"><figure class=\"aligncenter size-large\"><a href=\"https:\/\/www.testpreptraining.ai\/microsoft-azure-administrator-associate-az-104-free-practice-test\" target=\"_blank\" rel=\"noopener noreferrer\"><img decoding=\"async\" src=\"https:\/\/www.testpreptraining.ai\/tutorial\/wp-content\/uploads\/2020\/07\/testpreptraining.ai-2-1-750x117.png\" alt=\"AZ-104 Online Course\" class=\"wp-image-12856\"\/><\/a><\/figure><\/div>\n\n\n\n<p class=\"has-text-align-right\"><strong>Reference: <a href=\"https:\/\/docs.microsoft.com\/en-us\/archive\/blogs\/poshchap\/active-directory-bulk-user-modification\" target=\"_blank\" rel=\"noreferrer noopener\">Microsoft Documentation<\/a><\/strong><\/p>\n\n\n\n<p><strong><a href=\"https:\/\/www.testpreptraining.ai\/tutorial\/exam-az-104-microsoft-azure-administrator-associate\/\" target=\"_blank\" rel=\"noreferrer noopener\">Return to AZ-104 Tutorial<\/a><\/strong><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Return to AZ-104 Tutorial Page We shall now learn the process for bulk user updates in Active Directory. This is where automation plays a key role in making the tedious and the long-winded&nbsp;extremely easy. Let us suppose&nbsp;you have a huge data dump of user names with email addresses and phone numbers to be updated in&#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"_acf_changed":false,"footnotes":""},"categories":[174],"tags":[],"class_list":["post-12918","page","type-page","status-publish","hentry","category-microsoft-azure"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v22.1 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Bulk user Updates in Active Directory - Testprep Training Tutorials<\/title>\n<meta name=\"description\" content=\"Boost your learning and qualify AZ-104 exam with online tutorial and practice exam. Learn about Bulk user Updates in Active Directory. Try Now!\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.testpreptraining.ai\/tutorial\/bulk-user-updates-in-active-directory\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Bulk user Updates in Active Directory - Testprep Training Tutorials\" \/>\n<meta property=\"og:description\" content=\"Boost your learning and qualify AZ-104 exam with online tutorial and practice exam. Learn about Bulk user Updates in Active Directory. Try Now!\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.testpreptraining.ai\/tutorial\/bulk-user-updates-in-active-directory\/\" \/>\n<meta property=\"og:site_name\" content=\"Testprep Training Tutorials\" \/>\n<meta property=\"article:modified_time\" content=\"2022-03-07T04:14:37+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.testpreptraining.ai\/tutorial\/wp-content\/uploads\/2020\/06\/practice-test-2.png\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data1\" content=\"2 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.testpreptraining.ai\/tutorial\/bulk-user-updates-in-active-directory\/\",\"url\":\"https:\/\/www.testpreptraining.ai\/tutorial\/bulk-user-updates-in-active-directory\/\",\"name\":\"Bulk user Updates in Active Directory - Testprep Training Tutorials\",\"isPartOf\":{\"@id\":\"https:\/\/www.testpreptraining.ai\/tutorial\/#website\"},\"datePublished\":\"2020-07-22T06:35:13+00:00\",\"dateModified\":\"2022-03-07T04:14:37+00:00\",\"description\":\"Boost your learning and qualify AZ-104 exam with online tutorial and practice exam. Learn about Bulk user Updates in Active Directory. Try Now!\",\"breadcrumb\":{\"@id\":\"https:\/\/www.testpreptraining.ai\/tutorial\/bulk-user-updates-in-active-directory\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.testpreptraining.ai\/tutorial\/bulk-user-updates-in-active-directory\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.testpreptraining.ai\/tutorial\/bulk-user-updates-in-active-directory\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.testpreptraining.ai\/tutorial\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Bulk user Updates in Active Directory\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.testpreptraining.ai\/tutorial\/#website\",\"url\":\"https:\/\/www.testpreptraining.ai\/tutorial\/\",\"name\":\"Testprep Training Tutorials\",\"description\":\"\",\"publisher\":{\"@id\":\"https:\/\/www.testpreptraining.ai\/tutorial\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.testpreptraining.ai\/tutorial\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/www.testpreptraining.ai\/tutorial\/#organization\",\"name\":\"Testprep Training\",\"url\":\"https:\/\/www.testpreptraining.ai\/tutorial\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.testpreptraining.ai\/tutorial\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/www.testpreptraining.com\/tutorial\/wp-content\/uploads\/2020\/07\/tpt-logo-6.png\",\"contentUrl\":\"https:\/\/www.testpreptraining.com\/tutorial\/wp-content\/uploads\/2020\/07\/tpt-logo-6.png\",\"width\":583,\"height\":153,\"caption\":\"Testprep Training\"},\"image\":{\"@id\":\"https:\/\/www.testpreptraining.ai\/tutorial\/#\/schema\/logo\/image\/\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Bulk user Updates in Active Directory - Testprep Training Tutorials","description":"Boost your learning and qualify AZ-104 exam with online tutorial and practice exam. Learn about Bulk user Updates in Active Directory. Try Now!","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.testpreptraining.ai\/tutorial\/bulk-user-updates-in-active-directory\/","og_locale":"en_US","og_type":"article","og_title":"Bulk user Updates in Active Directory - Testprep Training Tutorials","og_description":"Boost your learning and qualify AZ-104 exam with online tutorial and practice exam. Learn about Bulk user Updates in Active Directory. Try Now!","og_url":"https:\/\/www.testpreptraining.ai\/tutorial\/bulk-user-updates-in-active-directory\/","og_site_name":"Testprep Training Tutorials","article_modified_time":"2022-03-07T04:14:37+00:00","og_image":[{"url":"https:\/\/www.testpreptraining.ai\/tutorial\/wp-content\/uploads\/2020\/06\/practice-test-2.png"}],"twitter_card":"summary_large_image","twitter_misc":{"Est. reading time":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.testpreptraining.ai\/tutorial\/bulk-user-updates-in-active-directory\/","url":"https:\/\/www.testpreptraining.ai\/tutorial\/bulk-user-updates-in-active-directory\/","name":"Bulk user Updates in Active Directory - Testprep Training Tutorials","isPartOf":{"@id":"https:\/\/www.testpreptraining.ai\/tutorial\/#website"},"datePublished":"2020-07-22T06:35:13+00:00","dateModified":"2022-03-07T04:14:37+00:00","description":"Boost your learning and qualify AZ-104 exam with online tutorial and practice exam. Learn about Bulk user Updates in Active Directory. Try Now!","breadcrumb":{"@id":"https:\/\/www.testpreptraining.ai\/tutorial\/bulk-user-updates-in-active-directory\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.testpreptraining.ai\/tutorial\/bulk-user-updates-in-active-directory\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.testpreptraining.ai\/tutorial\/bulk-user-updates-in-active-directory\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.testpreptraining.ai\/tutorial\/"},{"@type":"ListItem","position":2,"name":"Bulk user Updates in Active Directory"}]},{"@type":"WebSite","@id":"https:\/\/www.testpreptraining.ai\/tutorial\/#website","url":"https:\/\/www.testpreptraining.ai\/tutorial\/","name":"Testprep Training Tutorials","description":"","publisher":{"@id":"https:\/\/www.testpreptraining.ai\/tutorial\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.testpreptraining.ai\/tutorial\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.testpreptraining.ai\/tutorial\/#organization","name":"Testprep Training","url":"https:\/\/www.testpreptraining.ai\/tutorial\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.testpreptraining.ai\/tutorial\/#\/schema\/logo\/image\/","url":"https:\/\/www.testpreptraining.com\/tutorial\/wp-content\/uploads\/2020\/07\/tpt-logo-6.png","contentUrl":"https:\/\/www.testpreptraining.com\/tutorial\/wp-content\/uploads\/2020\/07\/tpt-logo-6.png","width":583,"height":153,"caption":"Testprep Training"},"image":{"@id":"https:\/\/www.testpreptraining.ai\/tutorial\/#\/schema\/logo\/image\/"}}]}},"_links":{"self":[{"href":"https:\/\/www.testpreptraining.ai\/tutorial\/wp-json\/wp\/v2\/pages\/12918","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.testpreptraining.ai\/tutorial\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.testpreptraining.ai\/tutorial\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.testpreptraining.ai\/tutorial\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.testpreptraining.ai\/tutorial\/wp-json\/wp\/v2\/comments?post=12918"}],"version-history":[{"count":5,"href":"https:\/\/www.testpreptraining.ai\/tutorial\/wp-json\/wp\/v2\/pages\/12918\/revisions"}],"predecessor-version":[{"id":52152,"href":"https:\/\/www.testpreptraining.ai\/tutorial\/wp-json\/wp\/v2\/pages\/12918\/revisions\/52152"}],"wp:attachment":[{"href":"https:\/\/www.testpreptraining.ai\/tutorial\/wp-json\/wp\/v2\/media?parent=12918"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.testpreptraining.ai\/tutorial\/wp-json\/wp\/v2\/categories?post=12918"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.testpreptraining.ai\/tutorial\/wp-json\/wp\/v2\/tags?post=12918"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}