cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
BastiOn
Engaged Sweeper III
Hy,

we have severel hundred users from a defunct domain. The users have been migrated to our active Domain.
Unfortunately the users wasn't delete in Lansweeper. Under "Active Directory Users OU" the domain and the users still stand.

How can i delete all users with SQL Command? I do not want to try this on the livesystem

Thanks
BastiOn

3 REPLIES 3
BastiOn
Engaged Sweeper III
Hy natebraun1

it works very nice

thx
natebraun1
Engaged Sweeper II
So, I went into SQL Server Manager and ran the following simple query.
Substitute your domain name for OLD_DOMAIN_NAME.

I got rid of them all real quick. Hit F5 on my browser, and they were gone.



Delete [lansweeperdb].[dbo].[tblADusers]
WHERE [Userdomain] = 'OLD_DOMAIN_NAME'
natebraun1
Engaged Sweeper II
Hello,

I have the same issue. We went through a merger last year and had two domains being scanned. Now, all users have been migrated, and we are left seeing duplicate users. Is there a bulk delete for users in the same way as assets?

Thank you,

Nate

New to Lansweeper?

Try Lansweeper For Free

Experience Lansweeper with your own data.
Sign up now for a 14-day free trial.

Try Now