copy a database

How do I copy a SQL server database?  This is SQL server 2000.
LVL 1
HLRosenbergerAsked:
Who is Participating?

[Webinar] Streamline your web hosting managementRegister Today

x
 
bitrefConnect With a Mentor Commented:
The best way is to Backup the database at source then restore at distination.
The backup restore is the best because:
It saves storage space
Can be performed while database is online and running
0
 
Anthony PerkinsCommented:
You can either:
1. Backup and restore or
2. Detach, copy data files and attach.
0
 
lundnakCommented:
You want to copy the database from SQL 2000 to SQL 2008?

There are several methods.
Detach the database
Copy the database files to the SQL 2008 server.
Re-Attach the database.
Setup the logins on the SQL 2008 Server.
   http://support.microsoft.com/kb/246133
Change Compatibility mode to SQL 2008 for the database and Page Verify option to "CheckSum"


Another method is to backup the SQL 2000 database.
Restore the backup file to the SQL 2008 server
Complete the last three steps described above.
0
Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

 
lundnakCommented:
Here is a MS article describing the attach/detach method.
http://support.microsoft.com/kb/224071
0
 
HLRosenbergerAuthor Commented:
No I want to make a copy of the 2000 database within the same server, with a different name of course.
0
 
lundnakConnect With a Mentor Commented:
Either method will work.

If you use Attach/Detach then you will need to detach the source database..
Copy the files to new file names.
Reattach the source database
Attach the copied files with a new database name.

If you use Backup/Restore, you will restore the database with a new name.  SSMS restore wizard will walk you through it.  Select the backup file and then change database name.
0
 
HLRosenbergerAuthor Commented:
Thanks
0
All Courses

From novice to tech pro — start learning today.