Composable Queries with Ecto
summary
Ecto queries become composable data pipelines: extract query construction from execution, use keyword and query‑expression syntaxes, compose named transformations (sources, transformations, syncs) and pipe queries through query pipeline stages. Builds a paginator, Scrivener, that returns page limit/offset entries and computes total counts by plucking out clauses (removing order/preload/select) so counts work even on complex queries; approach comes from real‑world apps and proves practical.
AI-written summary · about
chapters (7)
- 0:00Start
- 1:27Please ask questions
- 2:36Patterns from real applications
- 2:48A few models for examples
- 3:51Keyword query syntax
- 5:16Separate construction and execution
- 21:25Pipelines are fractal
related talks
42mBetter Data Access with Composable Queries
30mDiving into Ecto.Query
41mEcto: A language integrated query for Elixir
48mCompositional, Expressive, Performant Database Queries: Choose 3
35mElixir's Ecto: Functional Relational Data Access Done Right
41mEmbrace the Database With Ecto
37mLeveling Up With Ecto
49mScylla, Charybdis, and the mystery of Quill
