DDL synchronization from Oracle-compatible tenants of OceanBase Database to Oracle databases

2025-06-24 11:54:40  Updated

Supported DDL operations

  • CREATE TABLE

    Notice

    You can create partitioned tables but cannot use CREATE TABLE AS SELECT to create tables.

  • DROP TABLE

  • TRUNCATE TABLE

  • ADD PARTITION

    You can add partitions and subpartitions by using RANGE or LIST partitioning. HASH partitioning is not supported.

  • DROP PARTITION

    You can drop one or more partitions and subpartitions.

  • TRUNCATE PARTITION

    You can truncate one or more partitions and subpartitions.

  • RENAME TABLE and ALTER TABLE RENAME

  • ALTER TABLE ADD COLUMN

  • ALTER TABLE MODIFY COLUMN

    Notice

    You can increase the column length, but you cannot modify the column type.

  • CREATE INDEX

  • DROP INDEX

  • Adding or dropping comments on tables or columns

Limitations

  • Only the supported DDL operations can be synchronized. If the table to synchronize involves unsupported DDL operations, the migration task may be interrupted, which causes unrecoverable data inconsistencies.

  • Frequent DDL operations on a table are not supported. Continue with the next DDL operation only after the Store has completed the current one (judged by the position). Otherwise, the store may exit unexpectedly or cause unrecoverable data exceptions.

  • Make sure that no DDL operations are performed before you create a store and when a store is being started. If log pulling is involved, make sure that no DDL operations are performed during the period from the start time when logs are pulled to the current time. Otherwise, the store may exit unexpectedly or cause unrecoverable data exceptions.

  • The original and new table names in the RENAME TABLE statement must be names of the tables to be synchronized.

  • If you delete an unnamed primary key, the corresponding constraint whose name starts with SYS_C in the Oracle database is deleted. If you perform inter-database data migration or synchronization, for example, from an Oracle database to an OceanBase database, the primary keys in the OceanBase database cannot be deleted because they are different from those in the Oracle database.

  • When you migrate data from an Oracle-compatible tenant of OceanBase Database to an Oracle database, you cannot perform a DDL operation that changes a table with a primary key to a table without a primary key.

    • If a table in the Oracle-compatible tenant of OceanBase Database has a primary key, all DDL operations are supported.

    • If a table in the Oracle-compatible tenant of OceanBase Database has only a not-null unique key, a DDL operation that removes the not-null unique key is not supported.

  • Table creation DDL operations with the CASE WHEN INDEX clause are not supported for synchronization.

Contact Us