What is lazy true in hibernate?



What is lazy true in hibernate?..

Answer / Gaurav Saxena

In Hibernate, 'lazy=true' indicates that a relationship or property should be loaded on demand (i.e., when the associated data is actually needed), rather than being fetched immediately upon entity loading. This can help improve performance by reducing the amount of data initially loaded from the database.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Hibernate Interview Questions

Is it possible to perform collection mapping with one-to-one and many-to-one?

1 Answers  


How to write native sql query in hibernate?

1 Answers  


How transaction management works in Hibernate?

1 Answers  


Name some important interfaces of Hibernate framework?

1 Answers  


What is the use of ehcache?

1 Answers  


Is merge better than update?

1 Answers  


What is hibernate 2nd level cache?

1 Answers  


What are the states of object in hibernate?

1 Answers  


How to achieve mapping in hibernate?

1 Answers  


What is cascade in hibernate in which scenario we use it?

1 Answers  


How to write composite key mapping for hibernate?

1 Answers  


Explain the difference between criteria and criterion in hibernate?

1 Answers  


Categories