Including db and schema name before databasechangelogtable

Need help to setup liquibase for snowflake ,I am wondering if there is a way to include database and schema names with databasechangelog and lock table, This is needed because we have views/ procedures need to be created across multiple databases but databasechangelog table must be in specific schema and db.

I tried to change in liquibase.properties
databaseChangeLogTableName: db1.schema.masterlog
databaseChangeLogLockTableName: db1.schema.masterloglock

then liquibase adding quotes around insert into “db1.schema.masterlog” , either i should have statement like “db1”.“schema”.“masterlog” or without quotes db1.schema.masterlog.

tried with these in properties , but liquibaseSchemaName only working, catalog name is not including
liquibaseCatalogName:db1
liquibaseSchemaName:schema

Please suggest.
@nvoxland @r2liquibase

Hi @murali,
I had to deal with snowflake some time ago, if you give me a few days I will try the solution I had found again. You also need to setup snowflake.

sure, good to know if there is work around.

I also interesting in this because Snowflake switches schemas after schema creation which leads to immediate fail of Liquibase script - it stops see the schema which holds databasechnagelog tables.

Hi @murali,
sorry for the delay response. i tried to investigate about this, and i didn’t found a simple solution.
Refering to this:


i think it is possible to implement this.
But, in this period i don’t have too much time because i working on multiple task at the same time.

Try this because i didn’t had any issue to create liquibase tables in a specific db -> schema:

  • use jdbc:snowflake://<account_name>.snowflakecomputing.com/?<connection_params> without the db.
  • for liquibase databasechangelog and lock table use “dbname”.“schema_name”.“table_name”
  • the same for changesets “dbname”.“schema_name”.“table_name”

And make sure you have added the extension https://github.com/liquibase/liquibase-snowflake