ref
s,
those dbt models will be added to the current pipeline as upstream dependencies
to the dbt model you initially added.
mage_sources.yml
. This file is automatically generated and
updated whenever a new non-dbt model block is an upstream dependency of a dbt
model block.
If you have a Mage project named demo_project
with a dbt project named demo
,
here is an example of where the mage_sources.yml
file could be located:
mage_sources.yml
could look like this:
mage_[DBT_project_name]
.
The table names under the source follow this convention:
[pipeline_uuid]_[block_uuid]
.
To reference the preceding block in a dbt block use this convention:
{{ source('[source_name]', '[pipeline_uuid]_[block_uuid]') }
e.g.
{{ source('mage_demo', 'dbt_demo_pipeline_load_data') }
For more information on sources, read
dbt’s documentation.