Skip to content

Commit

Permalink
Semantic model configs in project.yml (#4144)
Browse files Browse the repository at this point in the history
## What are you changing in this pull request and why?

Semantic model configs for dbt project.yml

Closes: #3997

## Checklist

Uncomment if you're publishing docs for a prerelease version of dbt
(delete if not applicable):
- [x] Add versioning components, as described in [Versioning
Docs](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/single-sourcing-content.md#versioning-entire-pages)

- [x] Review the [Content style
guide](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/content-style-guide.md)
and [About
versioning](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/single-sourcing-content.md#adding-a-new-version)
so my content adheres to these guidelines.
- [x] Add a checklist item for anything that needs to happen before this
PR is merged, such as "needs technical review" or "change base branch."
  • Loading branch information
matthewshaver authored Oct 10, 2023
2 parents d677e73 + f6fdfca commit bdbfa4b
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions website/docs/docs/build/semantic-models.md
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,29 @@ semantic_models:
type: categorical
```
<VersionBlock firstVersion="1.7">
Semantic models support configs in either the schema file or at the project level.
Semantic model config in `models/semantic.yml`:
```yml
semantic_models:
- name: orders
config:
enabled: true | false
group: some_group
```

Semantic model config in `dbt_project.yml`:
```yml
semantic_models:
my_project_name:
+enabled: true | false
+group: some_group
```

</VersionBlock>

### Name

Define the name of the semantic model. You must define a unique name for the semantic model. The semantic graph will use this name to identify the model, and you can update it at any time. Avoid using double underscores (__) in the name as they're not supported.
Expand Down

0 comments on commit bdbfa4b

Please sign in to comment.