diff options
author | Collin Graves <collinrgraves@gmail.com> | 2016-01-27 21:54:34 -0600 |
---|---|---|
committer | Collin Graves <collinrgraves@gmail.com> | 2016-01-27 21:54:34 -0600 |
commit | 69d657db6faa24a237bebe564193a0a61decb01f (patch) | |
tree | abba63064d8078acd652f766130d46a810db23d6 /guides/source | |
parent | b2fe263fa66755521ba845a64dcbe3a1d86e3ff6 (diff) | |
download | rails-69d657db6faa24a237bebe564193a0a61decb01f.tar.gz rails-69d657db6faa24a237bebe564193a0a61decb01f.tar.bz2 rails-69d657db6faa24a237bebe564193a0a61decb01f.zip |
English explanation to multi-level nested join
Added an "Or, in English..." explanation to the "Joining Nested Associations (Multiple Level)" example.
Diffstat (limited to 'guides/source')
-rw-r--r-- | guides/source/active_record_querying.md | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/guides/source/active_record_querying.md b/guides/source/active_record_querying.md index 784be91845..63658e7c8b 100644 --- a/guides/source/active_record_querying.md +++ b/guides/source/active_record_querying.md @@ -1085,6 +1085,8 @@ SELECT categories.* FROM categories INNER JOIN tags ON tags.article_id = articles.id ``` +Or, in English: "return all categories that have articles, where those articles have a comment made by a guest, and where those articles also have a tag." + #### Specifying Conditions on the Joined Tables You can specify conditions on the joined tables using the regular [Array](#array-conditions) and [String](#pure-string-conditions) conditions. [Hash conditions](#hash-conditions) provide a special syntax for specifying conditions for the joined tables: |