I really like how in Rails 3 you can set the scope for your SQL as follows:
User.admins.to_sql
Is there a way to do the same with attitude has_many?:
User.first.jobs.to_sql
I tried User.first.jobs.public_methods.grep /sql/other tricks, but added nothing.
source
share