On Jun 5, 2:05 pm, etagwerker <[email protected]> wrote:
> Here is what I want to do:
>
> Departamento.all(:include => [:points]).to_json
Well, what I do is pretty ugly, but what I've taken to sprinkling
around the code is stuff like:
Departamento.all.points.to_a # FIXME force eager
[...]
Departamento.all.each{|d| [... do something with d here--this can
prevent the, ah, strategic eager loader from being able to help
later]}
[...]
Departamento.all.each{|d| [... do something with d's point here]}
In looking back over my own code, I don't actually do this with
Class.all.etc anywhere, so there's a chance it behaves differently.
--
You received this message because you are subscribed to the Google Groups
"DataMapper" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/datamapper?hl=en.