- Reference
- Version ยท 6.0
- Change Automation Reference
show-rows-affected
Last updated: September 29, 2026
The --show-rows-affected parameter controls whether Liquibase prints a X row(s) affected message to the console after each data manipulation language (DML) statement it runs. The default value is false.
Note: This parameter is available in Liquibase 6.0 and later.
Uses
In Liquibase 6.0+, --show-rows-affected lets you see how many rows each INSERT, UPDATE, or DELETE statement changed, without turning on SQL logging. It is set to false by default. Set it to true to turn the row counts on.
Before 6.0, row counts appeared only when you lowered --sql-log-level to FINE, which also printed the full text of every SQL statement Liquibase ran. SQL statements may contain sensitive values. To print only the affected row counts and not the SQL itself, use --show-rows-affected. In some cases, this can prevent sensitive values from being printed to the console. --show-rows-affected works independently of --sql-log-level, so you can set either one without affecting the other.
Liquibase prints the message only for statements that change data in your own tables. Keep the following in mind:
Writes to the Liquibase tracking tables,
DATABASECHANGELOGandDATABASECHANGELOGLOCK, are excluded. Your own tables whose names contain those words, such asmy_databasechangelog_backup, are still counted.Data definition language (DDL) statements such as
CREATE TABLEandALTER TABLEdo not produce a row count.If your JDBC driver does not report a count for a statement, Liquibase prints nothing for that statement.
Setting
--quietsuppresses the message, even when--show-rows-affected=true.
Note: The message is diagnostic output rather than a command result, so Liquibase writes it to STDERR along with the banner and progress messages. For more information, see Upgrading to Liquibase Secure 6.0.
Syntax
You can set this parameter in the following ways:
Option | Syntax |
Liquibase properties file (defaults file) |
|
Global flow file argument |
|
Global CLI parameter |
|
JVM system property (JAVA_OPTS environment variable) | Unix:
Windows:
|
Liquibase environment variable |
|
For more information, see Working with command parameters.
Output
The following examples show the console output of an update command that runs one changeset with a single INSERT statement that adds three rows to a person table.
Both runs end with a row total in the success message. Setting --show-rows-affected=true adds a separate line for each INSERT, UPDATE, or DELETE statement that Liquibase runs, above the update summary.
Default (show-rows-affected=false)
Enabled (show-rows-affected=true)
Related links
sql-log-level. Set the log level for the SQL statements Liquibase runs.
log-level. Set the log level for Liquibase output.
Upgrading to Liquibase Secure 6.0. Stream routing and other changes in Liquibase Secure 6.0.