SQL 2000 Database without name

  • The empty name database disturbs the DMO from functioning in all databases.

    How can I please get rid of this DB.

    Tried all kind of tricks (Enterprise Manager, 'Drop Database'....) but no go.

    Now I am unable to use the Scripting object feature.

    Please your help.

    Thanks

  • What do you see is sysdatabases?

    Have you tried dropping it from Query Analyser too? If so, what error message do you get?

    Did it have a name and it was renamed? I was unaware you could create a database without a name?

  • did you try this:

    select'[' + name + ']' from master.dbo.sysdatabases

    and then trying to drop the database in quesiton, including the brackets?

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • just tested it:

    create database [ ]

    drop database [ ]

    the above works..

    create database [ ]

    Server: Msg 1038, Level 15, State 3, Line 1

    Cannot use empty object or column names. Use a single space if necessary.

    Server: Msg 170, Level 15, State 1, Line 1

    Line 1: Incorrect syntax near ''.

    the forum makes it hard to read..create database[singlespace] works...nothing between brackes fails.

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • Thanks, so you replicated my problem.

    And I still can not get rid of the 'No Name Database' and it blocks all DMO operations on all of my other databases.

  • What output do you get when you run this query?

    [font="Courier New"]select HexName=convert(varbinary,name), name from master.dbo.sysdatabases order by name[/font]

  • what was the results of the query i posted?

    was it 'No Name Database' literally?

    did you try drop database [No Name Database]?

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • select HexName=convert(varbinary,name), name from master.dbo.sysdatabases order by name

    HexName name

    --------------------------------

    0x

    drop database [No Name Database]

    Cannot drop the database 'No Name Database', because it does not exist in the system catalog.

  • --create database [ ] --example where i created a badly named database

    select dbid,'[' + name + ']' from master.dbo.sysdatabases

    results:

    1 [master]

    2 [tempdb]

    3 [model]

    4 [msdb]

    5 [pubs]

    6 [Northwind]

    7 [TextManip]

    8 [dnn4]

    9 [dnn3]

    10 [CENSUS]

    11 [StormCensusZip]

    12 [ ]

    13 [GEO]

    15 [TempleArts]

    16 [DNN4FINAL]

    drop database [ ] --the one i want to drop, with blank name

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

  • Avraham de-Haan (10/23/2007)


    select HexName=convert(varbinary,name), name from master.dbo.sysdatabases order by name

    HexName name

    --------------------------------

    0x

    drop database [No Name Database]

    Cannot drop the database 'No Name Database', because it does not exist in the system catalog.

    That output shows a database with an empty string for a name. That is not allowed by the normal commands (CREATE DATABASE, sp_renamedb, etc.). Something has gone wrong somewhere, maybe a direct update to a system table.

    Unless you know what caused this problem, I think you would be better off contacting Microsoft for tech support on this issue.

    I don't understand why you are trying to run the "drop database [No Name Database]" command, since you do not have a database named "No Name Database".

Viewing 10 posts - 1 through 10 (of 10 total)

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