The RENAME DOMAIN command changes the name of an existing domain.
In order to execute the RENAME DOMAIN command on a domain, the user authorization must own the domain, own or possess OWNER privileges on the schema to which the domain belongs, or possess DBA privileges.
old domain name
This is the name of an existing domain. The domain name may be qualified with a schema name (that is, schema-name.domain-name) to rename a domain that is not in the current schema.
new domain name
This is the new name for the domain indicated by old domain name. The new domain name must not match the name of any other domain in the specified schema, and cannot be qualified with a schema name since the new name applies to the domain identified in the old domain name argument. It is strongly recommended that none of the SAND CDBMS SQL keywords be used as a new domain name, as this may cause problems when referencing the domain in certain SQL statements.
The keyword TO may optionally precede this argument.
The RENAME DOMAIN statement changes the name of a specified domain. The new domain name can be up to 128 characters long and must be unique among all domain names in the schema that contains the domain. All other restrictions on database object names apply to the new domain name. (Consult the section SAND CDBMS SQL Database Objects and Language Elements: Object Names for more information about database object names.)
RENAME DOMAIN vip.d_politics d_party;
The above example changes the name of the domain d_politics to d_party in the vip schema. If the domain was not qualified with its schema name, SAND CDBMS would look for the d_politics domain in the current schema.