I need to copy a active DB to a test db on the same machine. Can someone tell
me how to do this.
Thanks
Do a backup (BACKUP DATABASE) of the database, then do a RESTORE DATABASE with a new database name
and use the MOVE option of the RESTORE command to specify new physical database file names.
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://sqlblog.com/blogs/tibor_karaszi
"Stup88" <Stup88@.discussions.microsoft.com> wrote in message
news:51E2B75B-3558-4DED-84AF-1FDEE95C703E@.microsoft.com...
>I need to copy a active DB to a test db on the same machine. Can someone tell
> me how to do this.
> Thanks
|||Does the database I am backing up need to be offline or can I do that live
with people accessing it ?
"Tibor Karaszi" wrote:
> Do a backup (BACKUP DATABASE) of the database, then do a RESTORE DATABASE with a new database name
> and use the MOVE option of the RESTORE command to specify new physical database file names.
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://sqlblog.com/blogs/tibor_karaszi
>
> "Stup88" <Stup88@.discussions.microsoft.com> wrote in message
> news:51E2B75B-3558-4DED-84AF-1FDEE95C703E@.microsoft.com...
>
|||You can do it live, no problems (it will use some machine resources, of course, but not lock any
data or so).
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://sqlblog.com/blogs/tibor_karaszi
"Stup88" <Stup88@.discussions.microsoft.com> wrote in message
news:BB4F039D-AF4F-4F01-A53D-0B52F451CF04@.microsoft.com...[vbcol=seagreen]
> Does the database I am backing up need to be offline or can I do that live
> with people accessing it ?
> "Tibor Karaszi" wrote:
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment