[Rails] Re: Nested has_many queries in AR?
Marnen Laibow-Koser wrote in post #955562:
> That example contains some irrelevant key fields, aimed more at a
> habtm-type setup than what you're doing.
>
> What you're doing is described exactly in the last paragraph of the
> section you referred to, starting at 'The has_many :through association
> is also useful for setting up "shortcuts"....'. The example there
> matches your use case exactly: Document is A, Section is B, and
> Paragraph is C.
Hmm. Yeah that seems obvious now. I guess I obsessed on the diagram
(ooo, pretty picture!) and didn't really digest that lat paragraph.
Thanks!
-- gw
--
Posted via http://www.ruby-forum.com/.
--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home