stone wrote:
Thanks for reply.
Yes, I would like to have references between entities.
If I am not wrong in NHibernate is possibility to set how the queries will be executed, in one query or as in llblgen in a few queries, one for each entity.
NHibernate offers indeed that option, but their prefetch path feature is less powerful (you have to specify the parent-child setup yourself for example with the merging as well). The feature of having everything in 1 query isn't implemented in LLBLGen Pro as it is very often less optimal. The problem is that you have to join every node element's set to the parent's set. This leads to duplicate rows (for the parents) and this increases even more if you have multiple branches in your path. So if I want to fetch customer - Order - OrderDetails and also Order - Employee, I get a set with
Customer JOIN Order Join Order Details Join Employee
this could lead to a lot of duplicate Customer rows. This is particular bad, because the duplicated rows have to be filtered out on the client. With multiple queries, one per set, you don't have this problem, the sets are small and materializing the entities is easier too and thus faster.