Please HELP
I have a task in hand where i need to copy ExtensionAttribute14 to 9. This needs to be a script which i can run daily with the Task Scheduler. I need to ensure that this script does not consume much resources. The domain has around 80000 users.
I have exported the data in csv file that includes the SamAccountName,ExtensionAttribute14 and ExtensionAttribute9 with the below one liner.
$data1 = Get-ADUser -SearchBase “DC=xyz,DC=com” -LDAPFilter ‘(extensionAttribute14=*)’ -Properties * | Select-Object SamAccountName,extensionattribute14,extensionattribute9
$data1 | Export-csv C:\users\User1\Documents\data1.csv -NoTypeInformation
Now i need to compare Values in extensionattribute14 and extensionattribute9 in this csv file and create a new csv file with the difference. Then i need use the new csv file that has the difference and copy the value from extensionattribute14 to extensionattribute9 from this new CSV file.
Please help with this.