Why do use lazy="false"?


It decides whether the child object is loading to the parent or not.
  1. We have to set it in the mapping file of the parent class.If lazy="true" (means not to load child)
  2.  By default the lazy loading is true.
  3.  But some cases we need to load the child object when the parent is loaded.
  4.  So in that case we'll have to write lazy="false".

No comments:

Post a Comment