This project is archived and is in readonly mode.

#287 ✓resolved
Brandon Keepers

Associations' dynamic finders fail with :order depends on :include

Reported by Brandon Keepers | May 31st, 2008 @ 11:43 PM | in 2.1.1

This ticket was originally submitted on trac

Dynamic finders generate invalid queries when they are called on an association like: has_many :posts, :include => :comments, :order_by => 'comments.position' because :include is getting ignored. (using non-dynamic #find() works correctly)

I've attached test cases that cause this error and a patch to fix it. Tested against Trunk.

Comments and changes to this ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href=""></a>