Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 Copy DataBase

Author  Topic 

ren.hik
Starting Member

4 Posts

Posted - 2009-03-04 : 06:22:53
hi All,
I need to copy an Entire Data base to another server or may in the same server with differnt DataBase names But with the same content of the previous Database, including all the Data Bse objects(like tables, views... and mainly DTS)

can u pl help me regarding this Issue.
IMP and URGENT.


thanks in Advance,
ren.

You Fear Your Own Destiny.!?

NeilG
Aged Yak Warrior

530 Posts

Posted - 2009-03-04 : 06:51:14
Have you looked at the 'copy database' under the task in ssms, try the following

Rightclick on the database you require select tasks for the list and then see at the bottom of that list a copy databases option.
Go to Top of Page

darkdusky
Aged Yak Warrior

591 Posts

Posted - 2009-03-04 : 11:16:33
Create a full backup and restore from the backup - you can change the name it is restored as. Either put new name into restore wizard textbox "To database"
or change name in restore statement, e.g.
restore database NewName from disk = N'C:\temp\oldName.bak' with File =1, NOUNLOAD, STATS = 10, REPLACE
Go to Top of Page

JasperK
Starting Member

2 Posts

Posted - 2009-03-06 : 04:36:43
Is it also possible to automate this process?

For example; Steps to copy a database from server 1 to server 2:

1) On server 1: Backup database to file..
2) Copy the file to another server..
3) On server 2 -> Restore database from file.

Is there an easier sollution for MS SQL 2005?

many thanks in advance
Go to Top of Page

darkdusky
Aged Yak Warrior

591 Posts

Posted - 2009-03-06 : 04:49:44
Yes you can automate it.
You should already have a full backup running automatically.
Schedule a script to copy the full backup to a folder on new server and delete old ones in the new location.
Have a restore job to restore second server from the copied backup.
http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=118175
Go to Top of Page

JasperK
Starting Member

2 Posts

Posted - 2009-03-06 : 05:52:50
Thanks!

Is it also possible to do it 'on the fly'?
For example you can restore a database from another database on the same server by right click destination database, restore, from database. etc..

I'd like to see more of less te same, only source database on a different server than the destination database (without creating backup files).

Regards, Jasper
Go to Top of Page
   

- Advertisement -