Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fix typo where a table name in a join was singular.

  • Loading branch information...
commit 256e317c390ef6f8ce9e033e2440a5665ef9d898 1 parent 749ced1
Don Petersen dpetersen authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  guides/source/active_record_querying.textile
2  guides/source/active_record_querying.textile
View
@@ -834,7 +834,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". 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)").
+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(:posts).select("distinct(categories.id)").
h5. Joining Multiple Associations
Please sign in to comment.
Something went wrong with that request. Please try again.