If you need to create a database that is the same as an existing database, you can copy the database. This topic describes how to copy a database to a new database in the ApsaraDB for RDS console.

Prerequisites

The instance version is ApsaraDB RDS SQL Server 2008 R2.

Note You can only execute SQL statements to copy databases of ApsaraDB RDS SQL Server 2012 and later. For more information, see Copy a database of ApsaraDB RDS SQL Server 2012 or later.

Precautions

  • Only one database can be copied at a time.
  • The names of the new database and the existing database must be different.

Procedure

  1. Log on to the ApsaraDB for RDS console.
  2. In the upper-left corner of the page, select the region where the instance is located.Select a region
  3. Find the instance and click the instance ID.
  4. In the left-side navigation pane, click Databases.
  5. Click Copy Database.
  6. Enter the information of the new database.
    Parameter Description
    Enter a Database Name The database name must be up to 64 characters in length and can contain lowercase letters, digits, underscores (_), and hyphens (-). It must start with a letter and end with a letter or digit.
    Select the Database to Copy Select the database that you need to copy from existing databases.
    Do You Want to Keep the Account Information from the Source Database Specify whether to retain the account and authorization information of the source database in the new database. By default, the information is retained. You can retain as needed.
    Description You can enter the information of the database for easy task identification. You can enter up to 256 characters.
  7. Click OK.