August 6, 2013 at 5:44 am
Comments posted to this topic are about the item Delete All Database User Accounts for a Given Server Login
Hakim Ali
www.sqlzen.com
April 14, 2014 at 3:21 am
This is good topic but I want to delete 2 users forcefully from 253 databases then how can i do it?
April 14, 2014 at 7:25 am
Prat!K (4/14/2014)
This is good topic but I want to delete 2 users forcefully from 253 databases then how can i do it?
Towards the top of my script there is this line:
set @LoginName = 'LOGIN_NAME_HERE'
Set the server level login name associated with one of your users here, and run the script. Then set @LoginName to the login name of your other user, and run the script again. This will accomplish what you want. I'm assuming these two users and the 253 databases are on the same server. If they are on more than one server, just repeat the process on each server.
Hakim Ali
www.sqlzen.com
May 5, 2015 at 6:58 am
Great script, thanks.
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply