Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Fixes for methods that use raw sql to work properly with scopes that use joins #38

Merged
merged 2 commits into from Apr 22, 2011

Conversation

Projects
None yet
6 participants
Contributor

raelik commented Feb 14, 2011

Because the descendants, subtree and subtree.arrange methods use raw sql as part of their conditions, using them with another scope method breaks if that scope uses joins. These commit fix that by adding the table name to the sql. Any other instances I find like this that break joins, I'll commit to this branch.

Blane Dabney added some commits Dec 17, 2010

Blane Dabney Fix descendants and subtree methods to work properly with scopes that…
… use joins by including the table name in the condition sql.
95afdd0
Blane Dabney Fix ordered_by_ancestry and ordered_by_ancestry_and scopes to work pr…
…operly with scopes that use joins by including the table name in the condition sql.
5e0757a

swrobel commented Feb 14, 2011

Second this!

This would be great.

please merge this!

@stefankroes, could you merge this? :)

Owner

stefankroes commented Apr 22, 2011

sorry for the long wait. merged

@stefankroes stefankroes reopened this Apr 22, 2011

@stefankroes stefankroes merged commit 5e0757a into stefankroes:master Apr 22, 2011

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment