Copy edits 64148ab96b (previous commit). Please squash at will.

This commit is contained in:
Ben Orenstein
2011-05-26 22:22:10 -04:00
committed by Xavier Noria
parent 5eaf012673
commit 97fd8c0ffd

View File

@@ -704,7 +704,7 @@ SELECT categories.* FROM categories
INNER JOIN posts ON posts.category_id = categories.id
</sql>
Or, in English: "return a category object for all categories with posts". (You will see duplicate categories if more than one post has the same category. If you want unique posts, you can use Category.joins(:post).select("distinct(categories.id)).)
Or, in English: "return a Category object for all categories with posts". Note that you will see duplicate categories if more than one post has the same category. If you want unique categories, you can use Category.joins(:post).select("distinct(categories.id)").
h5. Joining Multiple Associations