The sys tenant can rename a user tenant.
At present, OceanBase Database allows you to rename only user tenants.
Procedure
Log on to the
systenant of the cluster as therootuser.Rename a user tenant.
The syntax is as follows:
ALTER TENANT old_tenant_name RENAME GLOBAL_NAME TO new_tenant_name;Rename
tenant1astenant2.obclient> ALTER TENANT tenant1 RENAME GLOBAL_NAME TO tenant2;
References
For more information about the ALTER TENANT statement, see ALTER TENANT.