Writing Queries with Schemas
Programming Ecto — Pragmatic Programmers (30 / 122)
👈 Creating Schemas | TOC | Inserting and Deleting with Schemas 👉
When we looked at queries in the last chapter, we deliberately chose to write them without schemas. This is still a good choice in some circumstances, but schemas provide some helpful shortcuts and we promised that we’d revisit them later. Now’s the time. In this section, we’ll start writing queries that work with schemas, and we’ll also consider when it’s best not to.