Solved

How to remove an offline database

Posted on 2008-10-28
13
1,061 Views
Last Modified: 2012-05-05
How can I remove an offline database, I cannot bring it online anymore becasue of a failure (set offline failed for Database 'AA'

Can seomone help me?
0
Comment
Question by:AGION
  • 7
  • 6
13 Comments
 
LVL 60

Expert Comment

by:chapmandew
ID: 22823768
you could just detach it if you're able to access it.

0
 

Author Comment

by:AGION
ID: 22824815
I also cannot detach it....
0
 
LVL 60

Expert Comment

by:chapmandew
ID: 22824832
can you drop it?

drop database dbname
0
 

Author Comment

by:AGION
ID: 22825056
If i Try that using a query if gives me the following message;
 

Msg 942, Level 14, State 4, Line 1
Database 'Ijsselstein' cannot be opened because it is offline.
0
 
LVL 60

Expert Comment

by:chapmandew
ID: 22825116
you don't need to try to connect to the db...run the statement in the context of the master db.
0
 

Author Comment

by:AGION
ID: 22825147
I run it from the master database;
like this:
DROP DATABASE [AA]
0
Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

 
LVL 60

Expert Comment

by:chapmandew
ID: 22825169
thats odd...it shouldn't matter that it is offline when you try to drop it.
0
 

Author Comment

by:AGION
ID: 22825208
I think that there a problem occured when the database was taken down, but no I can't do anything with the DB
Can I do something through Windows browser?
0
 
LVL 60

Expert Comment

by:chapmandew
ID: 22825243
One thing you could try is to restart sql server and then try it...if it doesn't work then, stop sql server, move the db files, and start it back up....
0
 

Author Comment

by:AGION
ID: 22825261
move the db files...where are they exactly located?
0
 
LVL 60

Expert Comment

by:chapmandew
ID: 22825293

run this in a db...will give you an idea as to where the others are.

select * from sys.database_files
0
 

Accepted Solution

by:
AGION earned 0 total points
ID: 22849255
It seems to be fixed in SP2 form SQL 2005
0
 
LVL 60

Expert Comment

by:chapmandew
ID: 22849261
good...it sounds nasty
0

Featured Post

Control application downtime with dependency maps

Visualize the interdependencies between application components better with Applications Manager's automated application discovery and dependency mapping feature. Resolve performance issues faster by quickly isolating problematic components.

Join & Write a Comment

So every once in a while at work I am asked to export data from one table and insert it into another on a different server.  I hate doing this.  There's so many different tables and data types.  Some column data needs quoted and some doesn't.  What …
In this article I will describe the Copy Database Wizard method as one possible migration process and I will add the extra tasks needed for an upgrade when and where is applied so it will cover all.
Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now