renameView
Renames an existing view.
Available attributes
Name | Description | Required for | Supports | Since |
---|---|---|---|---|
catalogName
|
Name of the catalog | all | 3.0 | |
newViewName
|
Name to rename the view to | all | all | |
oldViewName
|
Name of the view to rename | all | all | |
schemaName
|
Name of the schema | ingres, mariadb, mssql, mysql, postgresql, sqlite, sybase |

<changeSet author="liquibase-docs" id="renameView-example">
<renameView catalogName="cat"
newViewName="v_person"
oldViewName="v_person"
schemaName="public"/>
</changeSet>

changeSet:
id: renameView-example
author: liquibase-docs
changes:
- renameView:
catalogName: cat
newViewName: v_person
oldViewName: v_person
schemaName: public

{
"changeSet": {
"id": "renameView-example",
"author": "liquibase-docs",
"changes": [{
"renameView": {
"catalogName": "cat",
"newViewName": "v_person",
"oldViewName": "v_person",
"schemaName": "public"
}
}]
}
}

RENAME TABLE cat.v_person TO cat.v_person;
Database support
Database | Notes | Auto rollback |
---|---|---|
DB2/LUW | Not Supported | No |
DB2/z | Not Supported | No |
Derby | Not Supported | No |
Firebird | Not Supported | No |
H2 | Not Supported | No |
HyperSQL | Not Supported | No |
INGRES | Supported | Yes |
Informix | Not Supported | No |
MariaDB | Supported | Yes |
MySQL | Supported | Yes |
Oracle | Supported | Yes |
PostgreSQL | Supported | Yes |
Snowflake | Supported | Yes |
SQL Server | Supported | Yes |
SQLite | Not Supported | No |
Sybase | Supported | Yes |
Sybase Anywhere | Not Supported | No |