ALTER DATABASE mydb RENAME TO mydb2;
ALTER DATABASE IF EXISTS mydb RENAME TO mydb2;

ALTER DATABASE mydb SWAP WITH yourdb;
ALTER DATABASE IF EXISTS mydb SWAP WITH yourdb;

ALTER DATABASE mydb SET
  DATA_RETENTION_TIME_IN_DAYS = 7,
  MAX_DATA_EXTENSION_TIME_IN_DAYS = 14,
  DEFAULT_DDL_COLLATION = 'en_ci',
  COMMENT = 'My most excellent database'
;

ALTER DATABASE mydb SET TAG environment = 'test', billed_to = 'sales';

ALTER DATABASE mydb UNSET TAG environment, billed_to;

ALTER DATABASE mydb UNSET DATA_RETENTION_TIME_IN_DAYS, DEFAULT_DDL_COLLATION;
