Change: ‘dropColumn’

Drop an existing column

Available Attributes

NameDescriptionRequired ForSupportsSince
catalogNameName of the catalogall3.0
columnNameName of the column to dropallall
schemaNameName of the schemaall
tableNameName of the table containing the column to dropallall
<changeSet author="liquibase-docs" id="dropColumn-example">
    <dropColumn catalogName="cat"
            columnName="id"
            schemaName="public"
            tableName="person"/>
</changeSet>
changeSet:
  id: dropColumn-example
  author: liquibase-docs
  changes:
  - dropColumn:
      catalogName: cat
      columnName: id
      schemaName: public
      tableName: person
{
  "changeSet": {
    "id": "dropColumn-example",
    "author": "liquibase-docs",
    "changes": [
      {
        "dropColumn": {
          "catalogName": "cat",
          "columnName": "id",
          "schemaName": "public",
          "tableName": "person"
        }
      }]
    
  }
}

SQL Generated From Above Sample (MySQL)

ALTER TABLE cat.person DROP COLUMN id;

Database Support

DatabaseNotesAuto Rollback
DB2SupportedNo
DerbySupportedNo
FirebirdSupportedNo
H2SupportedNo
HyperSQLSupportedNo
InformixSupportedNo
MySQLSupportedNo
OracleSupportedNo
PostgreSQLSupportedNo
SQL ServerSupportedNo
SQLiteSupportedNo
SybaseSupportedNo
Sybase AnywhereSupportedNo

Missing, incomplete or wrong information? Please send a pull request