Working with Joins

Our queries have gotten more complex and expressive with the addition of the where option and all of the functions that can be used within it. But so far, we’ve only been working with one table at a time. When we need to query across multiple tables at once, we’ll need joins. In this section, we’ll see how to add joins to our queries, and also learn how to change our select option to make results from multiple columns easier to read.

What’s a join?

images/aside-icons/info.png

The term “join” comes from SQL. It’s a feature of the language that allows you to combine data from two or more tables within the same query. Joins come in many different ...

Get Programming Ecto now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.