I want to store my tables as managed tables on an external location like adls or blob.
By default databricks stores managed tables in: dbfs:/user/hive/warehouse, it is possible to change this default location by creating the database / schema and definining the location.
Example SQL statement:
CREATE DATABASE test_db LOCATION ‘abfss://firstname.lastname@example.org/test_db’
CREATE SCHEMA test_db LOCATION ‘abfss://email@example.com/test_db’
(database / schema are equivalent in databricks)
This way all tables created in this database/schema will be managed tables and the data as well as the metadata will be deleted if a table is dropped. I can’t find a way how to add the location to the create schema statement in dbt.
Consulted dbt documentation
How can I add the location to the CREATE DATABASE / SCHEMA statement in dbt in such tables within this database / schema will become managed tables and data is stored on an external storage account?