Eager loading all associations


#1

Hi Railers,

Is there a way to specify all relations in a :include option while
find()ing?
I have a model with a lot of associations, and sometimes i would like to
query for all them.
Something like Model.find(params[:id], :include => :all) would be nice.
Alternatively, i don’t know if there is a mehod to retrieve all model’s
associations, to do something like Model.find(params[:id], :include =>
Model.associations)

Thanks.