Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3630284
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T00:15:01+00:00 2026-05-19T00:15:01+00:00

I know this seems like a duplicate of another question , but it is

  • 0

I know this seems like a duplicate of another question, but it is not completely. I want to copy a production db (in use and critical) to another db on the same server, to allow doing some testing. What is the easiest safe way to do this ?
Here is my proposal (mostly found here):

BACKUP DATABASE srcDB TO DISK = 'D:\SQL\Data\srcDBtest.bak' WITH COPY_ONLY

RESTORE DATABASE testDB FROM DISK = 'D:\SQL\Data\srcDBtest.bak'
 WITH MOVE 'srcDB' TO 'D:\SQL\Data\testDB.mdf', 
 MOVE 'erpSql_log' TO 'D:\SQL\Data\erpsqlPH.ldf', REPLACE, STATS = 10

Is that going to work ? Should testDB be created before running this ? Can I use any name in the TO argument of MOVE ?

I cannot afford to make a mistake, so clarification is welcome.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-19T00:15:02+00:00Added an answer on May 19, 2026 at 12:15 am

    Due to the importance I would use Management Studio and follow the backup guides found on MSDN.

    • For Backup follow: How to: Back Up a
      Database (SQL Server Management
      Studio)
    • For Restore follow: How
      to: Create a New Database From an
      Existing Database Backup (SQL Server Management
      Studio)
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Ok, I know this seems like a duplicate question, but don't think it is.
I know this seems like a repeat question, but i've read all the others
I know this may seem like a math question but i just saw this
Now this may seem like a silly question, but I need to know how
I know this might seem a controversial question but it really is not meant
This seems like it should be something I already know. We need to run
I know this is a recurrent question but I cannot seem to be able
I know that it seems a duplicate entry, but I red all the posts
this seems straightforward enough, I don't know if it's a bug, or just something
I know this might seem strange on the face on it but, if I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.