Changeset 8707
- Timestamp:
- 01/23/08 17:06:40 (1 year ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/activerecord/lib/active_record/associations.rb
r8675 r8707 488 488 # before the actual model exists. 489 489 # 490 # Eager loading is not possible with polymorphic associations. Given 490 # Eager loading is not supported with polymorphic associations up to (and including) 491 # version 2.0.2. Given 491 492 # 492 493 # class Address < ActiveRecord::Base … … 500 501 # will raise <tt>ActiveRecord::EagerLoadPolymorphicError</tt>. The reason is that the parent model's type 501 502 # is a column value so its corresponding table name cannot be put in the FROM/JOIN clauses of that early query. 503 # 504 # In versions greater than 2.0.2 eager loading in polymorphic associations is supported 505 # thanks to a change in the overall preloading strategy. 502 506 # 503 507 # It does work the other way around though: if the <tt>User</tt> model is <tt>addressable</tt> you can eager load