Skip to content

Commit

Permalink
Improve the instructions for overriding a model from a package (#5078)
Browse files Browse the repository at this point in the history
## What are you changing in this pull request and why?

While researching dbt-labs/dbt-core#9762,
there were some opportunities to improve the readability of the relevant
docs.

## Checklist
- [x] Review the [Content style
guide](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/content-style-guide.md)
so my content adheres to these guidelines.
  • Loading branch information
mirnawong1 authored Mar 15, 2024
2 parents 5d7625d + 4b9ebd7 commit cbd3d1c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions website/docs/reference/resource-configs/enabled.md
Original file line number Diff line number Diff line change
Expand Up @@ -301,8 +301,8 @@ If you are disabling models because they are no longer being used, but you want

## Examples
### Disable a model in a package in order to use your own version of the model.
This could be useful if you want to change the logic of a model in a package. For example, if you need to change the logic in the `segment_web_page_views` from the `segment` package ([original model](https://github.com/dbt-labs/segment/blob/main/models/base/segment_web_page_views.sql)):
1. Add a model named `segment_web_page_views` the same name to your own project.
This could be useful if you want to change the logic of a model in a package. For example, if you need to change the logic in the `segment_web_page_views` from the `segment` package ([original model](https://github.com/dbt-labs/segment/blob/a8ff2f892b009a69ec36c3061a87e437f0b0ea93/models/base/segment_web_page_views.sql)):
1. Add a model named `segment_web_page_views` (the same name) to your own project.
2. To avoid a compilation error due to duplicate models, disable the segment package's version of the model like so:

<File name='dbt_project.yml'>
Expand Down

0 comments on commit cbd3d1c

Please sign in to comment.