Database Rename - Best Practice

matttrax
matttrax Member Posts: 2,309
We have a company called ABC, with database name ABC. They are running on SQL 2000. Company ABC has been bought by company XYZ and wants the database name (not company, but down to the database name level) to be XYZ, so that nothing about the old name remains.

What is the best way to rename the database? I don't see any options under File --> Database --> Alter. And I can't edit any of the file name fields there.

I don't know much about SQL or how it configures with Navision, so any help is great. Thanks.

Comments

  • Tomas
    Tomas Member Posts: 420
    I would go for:
    - creating new database (with new name, same settings)
    - creating backup of old database
    - restoring backup on the new database
  • bbrown
    bbrown Member Posts: 3,268
    Open SQL Query Analyzer and execute the following:


    EXEC sp_renamedb 'oldname' 'newname'
    There are no bugs - only undocumented features.