Does Your dbt Project Have More Models Than Anyone Can Explain?
ref() makes a new model a one line decision, and a project of hundreds of loosely governed SQL files is the result. Changing a business key upstream then means finding every model that inherited it. The fix is not more tests. It is a model that generates the structure instead of accumulating it.
Does this sound familiar?
- The DAG has hundreds of models and a handful of people who know why half of them exist.
- A change to a business key upstream breaks models three layers down that nobody remembered depended on it.
- The same staging logic exists in slightly different versions because copying a model was faster than reusing one.
- Refactoring is scheduled every quarter and completed in none of them.
dbt, now one company with Fivetran, made creating a model trivial. select * from ref('...')
and a new node exists. That is the feature, and over two or three years it is also how a
project grows into hundreds of models with lineage nobody can hold in their head. When
creating code has no friction, accumulation is the default outcome.
Why projects sprawl
- Forking is cheaper than changing. dbt has macros and packages for the standard patterns, but any developer can edit them, and changing a shared one properly means regression tests and migration scripts. So a pattern that does not quite fit gets a second version instead.
- Structure and logic live in the same files. A model that stages a source, one that handles history, and one that computes margin all look the same in the DAG.
- Dependencies are declared, not designed.
ref()records that a model reads another; it does not say why, or what breaks if the upstream key changes. - Governance arrives after the fact. Naming conventions, folders and tests are applied to a project that was already large by the time anyone wrote them down.
The tooling is not at fault. A framework that makes SQL modular will be used to write a lot of modular SQL.
Where the structure belongs
- Most models are structural. Staging, deduplication, key generation, history tracking: the same pattern per source, differing only in column names.
- Structural code should be generated, not accumulated. Declare the business key, the relationships and the attributes once, and derive the loading code from a pattern that no project edits.
- Logic is the part worth writing by hand. Business rules, metrics and mart shapes are a small share of the project and the part that deserves a code review.
What changes with Datavault Builder
Datavault Builder holds the structure in a visual model and generates hubs, links, satellites and their loads from it, so the repeated part of the project stops being files.
- One definition per concept. A customer hub with five sources is one hub and five mappings in the model, not fifteen models in a folder.
- Dependencies are derived. The load order and lineage follow from the model, so an upstream key change is visible before it is deployed, not after.
- Metadata travels through the layers. Types, keys and descriptions are declared once and carried from staging to the marts, instead of being repeated in every model file.
- Refactoring is a model edit. Change the mapping, regenerate, and every dependent structure is rebuilt consistently.
- The documentation is the model. Lineage, definitions and history rules are readable in one place, without a docs build.
- Business rules are managed in the model, with versions. The delivery layer is built by drag and drop on the semantic layer, so rules and data products have one home and a history.
- dbt can stay, generated. If operations remain in dbt, the dbt models are generated from the same model and regenerated on change, which is a much simpler way to update them than editing hundreds of files.
What to decide
Audit the project and sort each model by what it does: stages, keys, historizes, or computes. If the first three are most of the list, that is the structural share, and it is the share a generator should own.
See It Running on One of Your Sources
Book a free demo and bring the connector that costs you the most, in money or in time.
Three Steps to a Pipeline You Control
-
Separate structure from logic
Staging, keys and history are structure. Rules and metrics are logic. Most of the sprawl is structure.
-
Generate the structure
Hubs, links and satellites and their loads come from the model in Datavault Builder, one definition per business concept.
-
Deliver from the model
Marts and data products by drag and drop, rules versioned in the platform. Or generate dbt models if operations stay there.
How Datavault Builder Takes the Friction Out of Ingestion
-
Ingestion is built in
Batch, delta and CDC loads from databases, files, REST APIs, NoSQL and Python sources, with streams such as Kafka arriving as micro-batches. Same platform that generates the warehouse, no second invoice.
-
Your schema, not the vendor's
Source tables are mapped to a Data Vault 2.0 model you designed. A new column or a renamed table changes a mapping, not a chain of post-load scripts.
-
Only deltas move
Hubs, links and satellites load what changed. Full reloads stay in staging instead of being reprocessed downstream every night.
-
History is kept by design
Every change is retained as it arrives, so as-was reporting works even where the source overwrites its own rows.
-
Code you never hand-write
Loading, historization and lineage are generated from the model in real time and run natively on Snowflake, Databricks, BigQuery, SQL Server, Fabric, Oracle or PostgreSQL.
-
One platform, up to nine tools fewer
Modeling, ETL, CI/CD, documentation and lineage in one place. That is what makes 14.7 minutes from requirement to production possible.
Meet Our Expert
Twenty minutes with our Sales Director, and an honest answer on whether this fits your stack.
Matt Collett
Sales Director
Great, pick a time that works for you:
Other Problems This Series Covers
-
The dbt Trade-Off: Code Sprawl, Hidden TCO, and the Case for Automated Modeling
dbt brought software engineering to SQL, and teams are right to want that. The trade is a transformation layer that grows in code, in cost and in compute, on top of an ingestion tool that is still a separate product. A generated Data Vault takes that whole layer off the code base. It does not need dbt, but it can be combined with it.
-
Does dbt Still Leave You to Land the Data Yourself?
dbt is a transformation tool by design. It assumes the raw data is already in the warehouse, so the landing step is a second product with a second bill, even now that Fivetran and dbt Labs are one company. A warehouse platform that ingests and models in one place closes the gap without a second contract.
-
Is Your dbt Run Quietly Driving Up Warehouse Compute?
dbt executes everything in the warehouse, so a full refresh where an incremental would do, or a table materialization that rebuilds every night, shows up as credits, not as an error. Incremental logic is optional in dbt. In a generated Data Vault it is the only way loads are written.
Questions and Answers
- AutomateDV generates hub, link and satellite SQL from macros you configure per model, which is real progress over hand-written vault code. What stays yours is the staging layer, the metadata for every macro call, orchestration order, and history handling for changes in the source. In Datavault Builder those are derived from one visual model and updated when the model changes, and the model itself is the documentation. There is also a direct path across: the Migration Vault is a data model of hubs, links, satellites, sources and business keys. Map the metadata an AutomateDV project already has into it, and Datavault Builder generates a deployment package from that mapping.
- The model has one entry per business concept and source mapping, not one file per transformation step. A customer hub with five sources is one hub and five mappings, not fifteen models.
- Yes, in two ways. The generated vault and marts are ordinary tables and views, so existing dbt models can read them. And if you want to keep running operations through dbt, Datavault Builder generates the dbt models from its own model, so the sprawl does not come back: a change is made in the model and the dbt project is regenerated.