Could not find database ID 14

  • Hello everyone,

    I'm having a big problem here, and I would greatly appreciate your help.

    I clicked to Take Offline an SQL Server 2008 database, and since it seemed like it was gonna take long, I went and closed SQL Server Management Studio.

    When I open SSMS again, and try to expand "Databases" I get this error, and none of the databases are visible:

    "Could not find Database ID 14. Database may not be activated yet or it may be in transition. Reissue the query once the database is available."

    Can somebody please lend me some light into this issue? Never seen this error before.

  • Sounds like it's still being taken offline. Did you check the box to close the existing connections?

    Also, check your default trace file for your instance, and check your SQL Logs...post the results so we can see if there are any errors/problems.

    ______________________________________________________________________________Never argue with an idiot; Theyll drag you down to their level and beat you with experience

  • None of the databases at all?

    Not there, or just missing the +?

    Check the drives, make sure the drive with the database files is still accessible.

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • Actually I found out the databases were only invisible in object explorer, but visible in "New Query".

    I went to new query, and did the following command on the db I was taking offline, since I had done a backup:

    drop database DB_Name

    And walla!! Now all the other databases are visible in object explorer again and the error is gone :-D!

    By the way, the database files are still in the MSSQL Data Folder, it was like 30 minutes past already since I clicked to take offline, obviously there was something weird behind the scenes.

    Thanks for the info anyways, guys.

  • giontech (10/1/2011)


    By the way, the database files are still in the MSSQL Data Folder, it was like 30 minutes past already since I clicked to take offline, obviously there was something weird behind the scenes.

    If you drop a database that's been taken offline, the files won't be deleted. (it is documented behaviour)

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • GilaMonster (10/1/2011)


    giontech (10/1/2011)


    By the way, the database files are still in the MSSQL Data Folder, it was like 30 minutes past already since I clicked to take offline, obviously there was something weird behind the scenes.

    If you drop a database that's been taken offline, the files won't be deleted. (it is documented behaviour)

    Thanks.

    This would also apply while it is being taken offline, and the task hasn't finished right?

  • giontech (10/1/2011)


    GilaMonster (10/1/2011)


    giontech (10/1/2011)


    By the way, the database files are still in the MSSQL Data Folder, it was like 30 minutes past already since I clicked to take offline, obviously there was something weird behind the scenes.

    If you drop a database that's been taken offline, the files won't be deleted. (it is documented behaviour)

    Thanks.

    This would also apply while it is being taken offline, and the task hasn't finished right?

    If the process hadn't finished you wouldn't be able to drop the database as the session running the alter would still have an exclusive table lock.

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass

Viewing 7 posts - 1 through 6 (of 6 total)

You must be logged in to reply to this topic. Login to reply