aboutsummaryrefslogtreecommitdiffstats
path: root/guides/source/active_record_querying.md
diff options
context:
space:
mode:
authorVipul A M <vipulnsward@gmail.com>2016-04-09 14:31:15 +0530
committerVipul A M <vipulnsward@gmail.com>2016-08-09 14:14:53 +0530
commit0ee88bf1e780bb36e5c7b0237c43edf79c10bcff (patch)
tree20e5917dfd7928981701737267fcf7416dca7334 /guides/source/active_record_querying.md
parent92e20f398e3dbe8130f8d764701a195c14653e66 (diff)
downloadrails-0ee88bf1e780bb36e5c7b0237c43edf79c10bcff.tar.gz
rails-0ee88bf1e780bb36e5c7b0237c43edf79c10bcff.tar.bz2
rails-0ee88bf1e780bb36e5c7b0237c43edf79c10bcff.zip
Document know limitation about using `references` in conjunction with eager loading causing it to ignore custom select clauses.
[ci skip] Fixes #24314
Diffstat (limited to 'guides/source/active_record_querying.md')
-rw-r--r--guides/source/active_record_querying.md5
1 files changed, 3 insertions, 2 deletions
diff --git a/guides/source/active_record_querying.md b/guides/source/active_record_querying.md
index 8ffd0d033d..6f941d0e4e 100644
--- a/guides/source/active_record_querying.md
+++ b/guides/source/active_record_querying.md
@@ -1251,8 +1251,9 @@ articles, all the articles would still be loaded. By using `joins` (an INNER
JOIN), the join conditions **must** match, otherwise no records will be
returned.
-
-
+NOTE: If an association is eager loaded as part of a join, any fields from a custom select clause will not present be on the loaded models.
+This is because it is ambiguous whether they should appear on the parent record, or the child.
+
Scopes
------