Skip to content
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

Update reference-models-in-another-project.md #4209

Merged
merged 13 commits into from
Oct 10, 2023
Merged
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 14 additions & 4 deletions website/docs/faqs/Models/reference-models-in-another-project.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,19 @@ title: How can I reference models or macros in another project?
description: "Use packages to add another project to your dbt project"
sidebar_label: 'Reference models or macros in another project'
id: reference-models-in-another-project

keywords:
- project dependency, project dependencies, ref project, dbt mesh, multi-project, mesh, cross-project dependencies
---

You can use [packages](/docs/build/packages) to add another project to your dbt
project, including other projects you've created. Check out the [docs](/docs/build/packages)
for more information!
I dbt, you can manage dependencies across multiple dbt projects using:
mirnawong1 marked this conversation as resolved.
Show resolved Hide resolved
mirnawong1 marked this conversation as resolved.
Show resolved Hide resolved

1. **Packages**: You can import [packages](/docs/build/packages) as a way to add another project to your dbt project, including other projects you've created. When you install a project as a package, you bring in its entire source code, making its macros and models available in your own project.
mirnawong1 marked this conversation as resolved.
Show resolved Hide resolved

While this is useful for code reuse and sharing utility macros, it may not be the best approach for large-scale collaboration, especially in larger organizations.
mirnawong1 marked this conversation as resolved.
Show resolved Hide resolved

2. **Project dependencies**: You can use [project dependencies](/docs/collaborate/govern/project-dependencies) as an exciting way to depend on another project using the metadata service in dbt Cloud. It instantly resolves references to public models defined in other projects. You don't need to execute or analyze these upstream models yourself. Instead, you treat them as an API that returns a dataset. The responsibility for maintaining the quality and stability of these public models lies with their respective maintainers.
mirnawong1 marked this conversation as resolved.
Show resolved Hide resolved

This approach offers more flexibility and scalability for collaboration, making it easier to work with external projects while ensuring data quality and consistency.



Loading