aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVipul A M <vipulnsward@gmail.com>2016-08-22 18:09:21 +0530
committerGitHub <noreply@github.com>2016-08-22 18:09:21 +0530
commiteb8a1e2df8abffab82b7d7c3ddd75617c9aea4c8 (patch)
treee42c94f443cd59fd07e1c7fd41ec524e50f0665f
parent9ef56e51624ca7056599115eee3b43e248354bf7 (diff)
parent3b7642a328e35d6fb44f660dba96eb87008a84ad (diff)
downloadrails-eb8a1e2df8abffab82b7d7c3ddd75617c9aea4c8.tar.gz
rails-eb8a1e2df8abffab82b7d7c3ddd75617c9aea4c8.tar.bz2
rails-eb8a1e2df8abffab82b7d7c3ddd75617c9aea4c8.zip
Merge pull request #26245 from danila/quering-interface-guide
Change form of table name to plural in quering interface guides [ci skip]
-rw-r--r--guides/source/active_record_querying.md4
1 files changed, 2 insertions, 2 deletions
diff --git a/guides/source/active_record_querying.md b/guides/source/active_record_querying.md
index 0601c05e4b..493fd526fb 100644
--- a/guides/source/active_record_querying.md
+++ b/guides/source/active_record_querying.md
@@ -1014,13 +1014,13 @@ There are multiple ways to use the `joins` method.
You can just supply the raw SQL specifying the `JOIN` clause to `joins`:
```ruby
-Author.joins("INNER JOIN posts ON posts.author_id = author.id AND posts.published = 't'")
+Author.joins("INNER JOIN posts ON posts.author_id = authors.id AND posts.published = 't'")
```
This will result in the following SQL:
```sql
-SELECT clients.* FROM clients INNER JOIN posts ON posts.author_id = author.id AND posts.published = 't'
+SELECT clients.* FROM clients INNER JOIN posts ON posts.author_id = authors.id AND posts.published = 't'
```
#### Using Array/Hash of Named Associations