update-one-changeset
Last published July 28, 2025
Note: This is a Liquibase Pro feature, so you need a Liquibase Pro License Key to use it.
The update-one-changeset command lets you target and deploy any specific changeset in your changelog to your database. It is only available for Liquibase Pro users.
Uses
The update-one-changeset
command is helpful if your changelog contains several undeployed changesets and you want to deploy only one specific changeset, but not the others.
The update command deploys all changesets, and the update-count command deploys a specified number of changesets in sequential order. However, update-one-changeset
lets you deploy any single changeset anywhere in the changelog without affecting other undeployed changesets.
In Liquibase Pro 4.25.1 and later, you can automatically generate a database Update Report summarizing this command.
Impact
Like any targeted tool, using the update-one-changeset
command comes with risks of unintended consequences. Because of this, the command requires a --force
flag to indicate that you intend to run it.
Warning: Look for potential unintended consequences before using this command.
It is best practice to run the update-one-changeset-sql command because it allows you to inspect the update SQL and search for any potential mistakes before you execute update-one-changeset
.
Syntax
Before running the update-one-changeset
command, gather the following information from your changelog:
The author of the changeset you want to deploy.
The ID of the changeset you want to deploy.
The file path and name of the changeset you want to deploy.
Then run the update-one-changeset
command, with your information:
liquibase update-one-changeset --changelog-file=example-changelog.xml --changeset-id=2 --changeset-author=anotherdev --changeset-path=example-changelog.xml --force
For more command-specific help, type liquibase update-one-changeset --help
into the command prompt.
Note: The username
and password
attributes are not required for connections and systems which use alternate means of authentication. Also, you can specify database credentials as part of the url
attribute.
Parameters
Global parameters
Parameter | Definition | Requirement |
| Your Liquibase Pro license key | Required |
Command parameters
Parameter | Definition | Requirement |
| The root changelog | Required |
| The name of the author for the changeset. Supports | Required |
| The changeset ID from the changelog. | Required |
| The path to the changelog containing the changeset you want to target. For example, you may have a root changelog ( If If If you only have one changelog, then | Required |
| A required parameter which indicates you intend to use this feature. If you specify | Required |
| The JDBC database connection URL. | Required |
| Fully-qualified class which specifies a | Optional |
| Path to a properties file for the | Optional |
| Specifies the changeset contexts to match. Contexts are tags you can add to changesets to control which changesets are executed in any particular migration run. Note: If you use Liquibase 4.23.0 or earlier, use the syntax | Optional |
| Name of the default catalog to use for the database connection | Optional |
| Name of the default schema to use for the database connection. If Note: In the properties file and Note: In Liquibase 4.12.0 and later, you can use mixed-case schema names if you set | Optional |
| The JDBC driver class | Optional |
| The JDBC driver properties file | Optional |
| Liquibase Pro only. Use this argument only if you are specifying | Optional |
| Specifies the changeset labels to match. Labels are tags you can add to changesets to control which changesets will be executed in any migration run. | Optional |
| Password to connect to the target database. Tip: It is best practice to store sensitive data in a Secrets Management tool with Liquibase Pro. | Optional |
| Enables a report at the command level. Overrides the global parameter | Optional |
| Specifies the name of the report file at the command level. Overrides the global parameter | Optional |
| Specifies the file path to the report file at the command level. Overrides the global parameter | Optional |
| Liquibase 4.31.0+. Specifies whether to hide exceptions (which may contain SQL) from the operation report at the command level. Overrides the global parameter If If | Optional |
| Liquibase 4.31.0+. Specifies whether to hide changeset SQL in operation reports at the command level. Overridden by the global parameter | Optional |
| Liquibase Pro only. If any changeset in a deployment fails, Note: A changeset marked | Optional |
| Username to connect to the target database. Tip: It is best practice to store sensitive data in a Secrets Management tool with Liquibase Pro. | Optional |
When successful, the update-one-changeset
command produces the following output:
$ liquibase update-one-changeset --changeset-id=2 --changeset-author=anotherdev --changeset-path=example-changelog.sql --force
Running Changeset: example-changelog.sql::2::anotherdev
Liquibase command 'update-one-changeset' was executed successfully.
If you omit the --force attribute, Liquibase displays the following error:
$ liquibase update-one-changeset --changeset-id=2 --changeset-author=anotherdev --changeset-path=example-changelog.sql
Unexpected error running Liquibase: WARNING: Targeted update of this changeset may result in unexpected outcomes. To review the update SQL before executing it, please run 'update-one-changeset-sql'. This message can be suppressed by adding the --force flag.