-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
arbitrarily deep nesting #50
Milestone
Comments
Merged
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
#50
Summmary
This branch primarily addresses code cleanup/refactoring. In addition, it seemed like a good time to add arbitrary model nesting support. Everything can be arbitrarily deeply nested. This includes
.csv
files, model.sql
files,schema.yml
files, andanalysis
files!New
dbt_project.yml
model configurationsSuppose the root of your models repository looks like this:
You can structure your
models
config indbt_project.yml
to selectively configure models at any depth you want. You must specify the full path to a model in the config for its configuration to take affect. That is, if your file is located atmodels/saas_service/summary/domain_counts.sql
, your config should look like:Of course, if you just want to enable all models in
Your Project Name
, you can write:This works at any level of the config, and the most restrictive config that can apply to a model is used. Each level of the config "inherits" its parents config and can overwrite some or all of it.
A full example:
The text was updated successfully, but these errors were encountered: