Joined: Fri Jul 07, 2006 1:30 pm Posts: 6
|
Hibernate version: 3.1.1
I want to control in different cases whether Hibernate lazy loads a List member of an object or not. So can't do it in mapping.xml because it only configures it for the object and not for different transactions.
Can I map two similar objects to the same table. Both have same field properties and both have a List representing child objects. The only difference would be 1 object has the List set to Not lazy load, and the other has the List set to lazy load.
Doing it this way I could control the lazy loading by deciding which Object to use.
Would this work? I have not found another way to customize lazy loading at each different transaction level. This could be a cool workaround.
Comments please?
|
|