validate
The validate
command checks and identifies any possible errors in a changelog that may cause the update
command to fail.
Uses
Use the validate
command to detect if there are any issues with a changelog before running the update command. Validation helps you avoid a partial update, where only some changesets are applied due to an error in your changelog file.
Use the validate
command to ensure:
- The XML, YAML, JSON, or formatted SQL is structured correctly
- Referenced files can be found
- Any required or prohibited attributes are correct to your database
- There are no duplicated
id
,author
, andfile
combinations - There are no checksum errors
Note: The validate
command only looks for possible errors in the changelog, it does not check for possible errors that might result from applying the changes to a specific database.
Running the validate command
To run the validate
command, specify the driver, classpath, and URL in the Liquibase properties file. For more information, see Specifying Properties in a Connection Profile. You can also specify these properties in your command line.
Then run the validate
command:
liquibase --changelog-file=oracle_runWith_changelog.xml validate
Note: Enter the name of the changelog you want to use in place of oracle_runWith_changelog.xml
.
validate
global attributes
Attribute | Definition | Requirement |
---|---|---|
--changelog-file * |
The root changelog | Required |
--url
|
The JDBC database connection URL | Required |
--username
|
The database username | Required |
--password
|
The database password | Required |
* Liquibase will check nested changelogs for definitions of the changesets to validate.
Note: The username
and password
attributes are not required for connections and systems which use alternate means of authentication.

Liquibase Version: 4.9.1
Liquibase Community 4.9.1 by Liquibase
No validation errors found.
Liquibase command 'validate' was executed successfully.