Chaining Projections
Learn how to chain projections together to build multi-layer data architectures. This guide walks through the medallion architecture pattern as a practical example of projection chaining.
Projection chaining allows you to set one projection's source to another projection rather than the model. This creates a multi-layer architecture where data flows through a series of transformations, each layer building on the previous one. Chaining is the foundation for patterns like medallion architecture, data vault, and staged ETL pipelines.
How Chaining Works
By default, every projection sources from the canonical model. When you chain projections, you change a projection's source to point to an upstream projection instead. The downstream projection then sees the upstream projection's output as its input - including any renames, type changes, derived fields, and removed properties that the upstream projection applied.
Medallion Architecture Walkthrough
The medallion architecture is a common data engineering pattern with three layers: Bronze (raw), Silver (cleaned), and Gold (business-ready). Here is how to build it with projection chaining.
Setting the Source
To chain projections:
Considerations
Other Chaining Patterns
| Pattern | Layers | Use Case |
|---|---|---|
| Medallion | Bronze -> Silver -> Gold | Data lake architecture with progressive refinement |
| Data Vault | Staging -> Hub/Link/Satellite | Auditable enterprise data warehouse |
| API Gateway | Internal Types -> Public Contract | Expose a subset of internal types as a public API |
| Multi-Region | Canonical -> Region-Specific | Adapt data shapes for regional compliance requirements |
| Testing | Production Schema -> Test Fixtures | Generate test data shapes from production projections |