liquibase-catalog-name

The liquibase-catalog-name parameter specifies the catalog to use for Liquibase objects. It allows Liquibase to access a specific database catalog where Liquibase can store the DATABASECHANGELOG and DATABASECHANGELOGLOCK tables. The concept of a catalog varies between databases because not all databases have catalogs. For more information, refer to your database documentation.

Uses

A database catalog is typically an organized inventory of data assets in your database. It helps you collect and manage your metadata with the definitions of database objects, such as tables, views, synonyms, value ranges, indexes, users, and user groups.

You can use the liquibase-catalog-name parameter to specify the catalog in which to locate and store Liquibase objects created when running Liquibase operations.

Setting the liquibase-catalog-name parameter

You can set liquibase-catalog-name in four ways:

  • In the Liquibase properties file
  • As a global parameter in the CLI
  • As a JVM system property
  • As an environment variable (Liquibase Pro)

Liquibase properties file parameter

In Liquibase 4.1+, add the following to Liquibase properties file:

liquibase.liquibaseCatalogName: <string>

CLI global parameter

Tip: All commands and parameters use the --kebab-case format in the CLI environment. This is the format Liquibase recommends for best results. If your preference is camelCase, it will still work in the CLI.

In your command line, use a global parameter with a single Liquibase command:

liquibase --liquibase-catalog-name=<string> update --changelog-file=dbchangelog.xml

Java system property

In your command line, use the JAVA_OPTS Environment Variable to set a JVM system property:

Mac/Linux syntax:

JAVA_OPTS=-Dliquibase.liquibaseCatalogName=<string>

Windows syntax:

set JAVA_OPTS=-Dliquibase.liquibaseCatalogName=<string>

Note: To use a Liquibase command alongside JAVA_OPTS, add && liquibase <command> to the end of your input.

Environment variable (Liquibase Pro)

In Liquibase Pro, set an environment variable:

Mac/Linux syntax:

LIQUIBASE_LIQUIBASE_CATALOG_NAME=<string>

Windows syntax:

set LIQUIBASE_LIQUIBASE_CATALOG_NAME=<string>

Note: These environment variable commands only apply to the current shell. If you need to pass an environment variable to a child process without affecting the parent process, you can use the export command on Mac/Linux or the setx command on Windows.

Related links