Restore Users Deleted From AD Sync

This article addresses an issue where users are accidentally deleted through the Active Directory Sync feature of EIOBoard, then added back again, but all their status history and other information is missing.  This can happen when a user who was originally added through the AD Sync tool is unchecked from the AD Sync template and a manual or automatic sync runs.  By design, this will disable the user since they were added from AD Sync originally, but no longer appear on the template.  The same thing happens when a user is disabled in AD, then the AD Sync tool runs.

When this happens on accident, customers usually add the user back to the AD Sync template again and run a manual sync.  This will resync the Account if the Usernames still match, but if their username is not still the same, it will create a new account and all their status history and other information is missing.

There are two solutions to this problem.

  1. The first solution can be done by any user with EB Admin rights, but is generally only acceptable for a small number of users.  If you go into the Administrator, you can view disabled users.  This will show you the user(s) that were deleted from AD Sync (along with any other users that have been deleted manually through the administrator).  To solve this issue, simply disable the enabled user account, and then you will be able to enable the disabled user account that was deleted through the AD Sync tool.
  2. The second solution is more acceptable for a large number of deleted users, but requires knowledge of SQL, and may require assistance from Savance.  You will need to run the SQL commands below:

First, run these commands in SQL against your EIOBoard database to remove any users that were added on or after the day the AD Sync ran:
UPDATE Contacts SET CurrentValue = 0 WHERE ContactSys IN (SELECT ContactSys FROM Users WHERE DateCreated > ‘DateOfADSync’)
UPDATE Users SET CurrentValue = 0 WHERE DateCreated > ‘DateOfADSync’)

Just change “DateOfADSync” to the date you ran the AD Sync which removed your users.  Make sure to keep the single quotes and it should look something like: ‘2011-01-15’

Next, run these commands in SQL against your EIOBoard database to add back any users that were removed on or after the day the AD Sync ran:
UPDATE Contacts SET CurrentValue = 1 WHERE ContactSys IN (SELECT ContactSys FROM Users WHERE DateDeleted > ‘DateOfADSync’)
UPDATE Users SET CurrentValue = 1 WHERE DateDeleted > ‘DateOfADSync’)

Again, just change “DateOfADSync” to the date you ran the AD Sync which removed your users.  Make sure to keep the single quotes and it should look something like: ‘2011-01-15’

 

Was this article helpful?

Related Articles

Need Support?

Can't find the answer you're looking for?
Contact Support