May I ask how do I replicate a database on to another database in SQL server managament 2016?

Joshua Tay 246 Reputation points
2021-03-17T02:30:21.897+00:00

Hi,

I have server A and I want to replicate another Server A for testing purpose.

How do I do this?

I have tried to do a back up of Database A
Create a new Database and call it Database B
Then try to restore Database A in Database B.

78517-restoring-to-new-test-database.jpg

However, SQL gives me an error that said "the back up consist of contents belonging to another server"

Instead of restoring, should I be importing and exporting?

Thank you!
78524-error.jpg

SQL Server
SQL Server
A family of Microsoft relational database management and analysis systems for e-commerce, line-of-business, and data warehousing solutions.
12,759 questions
{count} votes

1 additional answer

Sort by: Most helpful
  1. AmeliaGu-MSFT 13,961 Reputation points Microsoft Vendor
    2021-03-17T07:36:02.037+00:00

    Hi @Joshua Tay ,

    The backup set holds a backup of a database other than the existing database

    Does the database you want to restore already exist on Server B?
    You can select the “Overwrite the existing database (WITH REPLACE)” on the Options tab of the Restore database page when restoring the database on server B.
    78654-01.jpg

    Best Regards,
    Amelia


    If the answer is helpful, please click "Accept Answer" and upvote it.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread