January 3, 2006 at 11:29 am
I've been reading about dropping DBs and Users.. and I'm not sure which order you would do this in.
I have a DR instance that I would like to cleanup so that I can run my DR scripts again and test. my questions are:
Is it best to drop the Logins from Master and THEN drop the Databases? Do I drop the logins from Master or from their Default DB?
I'm thinking that I will drop the Users from Master and then drop the Databases... anyone have any thoughts?
January 3, 2006 at 12:47 pm
That sounds about right. Either way if you drop the DB they will not be able to access it. Now if that login is used in multiple DB's then I would run a profiler to see how much that log in is used before blowing it away.
January 4, 2006 at 7:10 am
Thanks! I{'m not worried about blowing away the DBs or logins - I just didn't want to create a mess doing things in the wrong order since I will be blowing away and recreating the DBs and Logins mulitple times.
January 4, 2006 at 7:54 am
It shouldn't matter what order you do things in. A "login" in SQL is mapped to a "user" in a DB (or is it the other way around? ). Probably makes the most sense logically to drop the DB(s) and then the login(s), especially if you use the login for other DBs...
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply