DDL script to upper environment

KKo
Contributor III

I have multiple databases created in unity catalog in a DEV databricks workspace, I used databricks UI/notebook and ran scripts to do it. Now, I want to have those databases in QA and PROD workspaces as well. What is the best way to run those DDLs in upper environments? I don't want to go QA/PROD worspace UI or create notebook on them and run scripts to create them, rather I want to promote DDL script from DEV and run in QA/PROD. Any advice on this, how to achieve this in a simple way? 

szymon_dybczak
Esteemed Contributor III

Hi @KKo ,

The simplest way is to have a parametrized notebook which you can pass a name of your catalog as your parameter. Then you can use that parameter to prepare appropriate SQL statements responsible for creating catalogs/schemas/tables.

Alternatively, you can use tools like Flyway/Liquibase  that can help with CI/CD process of database objects

View solution in original post