NAV & SQL - Cleanup after deleting a user and before re-adding them?

We had an employee that was let go and then later rehired. In between that time, we deleted his Active Directory account (through Active Directory), but unintentionally left his NAV login/association intact.

When he was rehired, we created his login again in Active Directory, but when he went to log into NAV he would get “The login failed when connecting to the SQL Server NAVSERVER.”

We then removed and re-added his account in NAV, but he still gets the same error.

We noticed his SQL login username was still defined from his old Active Directory account.

We’re assuming that we can simply delete that old SQL login username/assocation, but we wanted to check to see if there was any other cleanup we needed to do before re-adding the SQL login. We’re trying to avoid having user GUID or other orphaned information floating around in NAV.

Thanks

Delete the previous user - in fact, relevant is user’s SID, not name.

When “recreated” as new AD account, user gets new SID.

Understood. So does the old SID need to be cleaned up anywhere in NAV or in SQL or is simply deleting the user in SQL enough?

Delete the old login in NAV, and check if it remains in SQL - if yes, delete that, too.There are no “other places” in NAV where related info is stored, so anywhere in NAV means just the logins.

This is for housekeeping, actually such orphaned logins can’t be (mis)used anymore, but there is no need to leave them hanging around, too. You can distinguish those orphaned ones in NAV login list easily - instead of username they contain SIDs (given that user is deleted from AD already).

HI, I am a little bit like john, I want reuse a login name from AD that has been deleted. When I create again the login , the SID change but the login name is the same. And then , dynamics Nav 2009 R2 dont allowed to reuse the same login name. I have a mistake and the login name dont enter in the table " Windows Login". if I change the login name for the same AD profil then dynamics accept it (and indeed the sid hasnt changed).