Can you someone help me understand this.
When I am eager loading something in the Model, like this:
Class Customer < ActiveRecord::Base
has_many :orders, :include => :line_items
( assume orders and line_items belongs_to customer, and order has_many
versus in the controller like this:
@customers = Customer.find(:all, :include => [:orders => :line_items])
I get different results.
Declaring the eager loading in the Model does not work.
But when I do it through the find, it works, I can see the data being
fetched in the SQL and I can see it in the instance variable.