Database User deleted

Hi all,

Very fresh MS SQL user calling. And I made horrible mistake, i am asking if possible to roll it back.

I am running MS SQL 2008 Developers edition. What I accidentally did is deleting the very one DB user on my local server!!!!! I have several DBs so it is very important to get back to my previous state.

Any chance? Please help me.

Thank you.

more ▼

asked Mar 29, 2010 at 06:33 AM in Default

avatar image

12 1 2 2

(comments are locked)
10|1200 characters needed characters left

1 answer: sort voted first

Did you take a backup?

Check "C:\Program Files\Microsoft SQL Server\MSSQL10.MSSQLSERVER\MSSQL\DATA" (this may differ depending on your installation). It maybe that the mdf and ldf of the database are still in the data folder. If so you can try re-attaching the mdf

MSDN "Attach Database"

more ▼

answered Mar 29, 2010 at 06:43 AM

avatar image

10.9k 27 37 37

My problem is I can not connect to the server itself. I have backups of my important DB, but not sure how can i use them when I can not connect to the DB server itself.

Mar 29, 2010 at 06:50 AM MpriorJ

OK.. Wrong end of the Stick... Are you a member of the "Local Admin" group? If so if you included this when you installed SQL then it should enable you in?

Where did you delete the user from? Logins or the specific database?

Mar 29, 2010 at 06:57 AM sp_lock

Yeah, I know it is really bad! I am member of all the admin groups in the network, but i never manage to add any other users to my local sever (the one on my PC) except mine. When I was deleting the user, the idea was to delete it from specific DB, but by mistake I delete it from the local server.

If this helps, i CAN connect to other MS SQL servers in the network, but not my local one.

To cut the story, I was wondering if there is any way to rollback the deletion?

Mar 29, 2010 at 07:05 AM MpriorJ

It work with little bit effort. Thank you very, very much. You saved me a lot of troubles! :)

Mar 29, 2010 at 08:40 AM MpriorJ
(comments are locked)
10|1200 characters needed characters left
Your answer
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here



Answers and Comments

SQL Server Central

Need long-form SQL discussion? SQLserverCentral.com is the place.



asked: Mar 29, 2010 at 06:33 AM

Seen: 2222 times

Last Updated: Mar 29, 2010 at 06:33 AM

Copyright 2018 Redgate Software. Privacy Policy