You will not have n+1 problems because of the relationships as long as you
use them correctly.
For the particular case that you mentioned, if you have a ParentId, you
don't even need to load the parent to get the children.


   Diego


On Wed, Dec 16, 2009 at 22:06, jmorris <[email protected]> wrote:

> Any advice on mapping tables directly to entities and using them as
> pure DTOs? Basically you ignore the foreign key reference as a child
> of the parent entity and explicitly load the children as needed:
> select * from children where children.parentid= xxx?
>
> I know this goes somewhat against the ORM grain, but when most of your
> usage is simply displaying list data, then this is a very per-formant
> way of getting what you need an avoiding any n+1 issues with ORMs. In
> this case your entities are just data, they are not even objects (data
> and behavior).
>
> Thoughts?
>
> --
>
> You received this message because you are subscribed to the Google Groups
> "nhusers" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected]<nhusers%[email protected]>
> .
> For more options, visit this group at
> http://groups.google.com/group/nhusers?hl=en.
>
>
>

--

You received this message because you are subscribed to the Google Groups 
"nhusers" 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/nhusers?hl=en.


Reply via email to