TableCommentCheck

The TableCommentCheck check allows you to flag any table that does not have a comment. Note that this is not a check for a Liquibase changelog comment.

Note: Checks require specific parameters noted in the table. Customizations to checks configuration are stored in the liquibase.checks-settings file.

Uses

You can use the check to check for the presence of a comment within a table described in a changelog. Comments explain the purpose of a table for anyone viewing the table.

Note: Quality Checks for Databases are only compatible with Relational databases verified as Advanced. Learn more about Database Verification Levels here: Database Verification and Support

Run the TableCommentCheck check

To run the TableCommentCheck check, ensure you have a Liquibase Pro license key, a valid URL property, a URL property pointing to a live JDBC connection or a snapshot, and the checks-scope property includes database. The checks-scope parameter is set in the default properties file, environment variable, or any standard method. Then check the table for comments. Enable the TableCommentCheck check by running the following command in the CLI:

liquibase checks enable --check-name=TableCommentCheck

TableCommentCheck configurable attributes

Attribute Name Type Description Customization Default Value
SEVERITY String/enum

Set the severity to return a code of 0–4 when the check is triggered. Default: 0.

  • 'INFO' | 0
  • 'MINOR' | 1
  • 'MAJOR' | 2
  • 'CRITICAL' | 3
  • 'BLOCKER' | 4

'INFO' | 0