Which class elements are not persisted?
Answer / Ashish Kumar Johri
In Hibernate, the following class elements are not persisted by default:
1. Transient variables - These are initialized only at runtime and their values are not stored in the database.
2. Static variables - These are shared among all instances of a class and their values are not specific to any object instance, hence they are not persisted.
3. Final variables - Once assigned, these variables cannot be changed during runtime. As such, final variables are initialized at compile-time and do not need to be stored in the database.
| Is This Answer Correct ? | 0 Yes | 0 No |
What are the benefits of hibernatetemplate?
What is difference between session get() and load() method in hibernate?
What is one to many and many to many relationships one to many?
How to update data in database using spring and hibernate?
What is session object in hibernate?
Which hibernate object wraps the jdbc connection?
What are the configuration files in hibernate?
Can we create multiple sessionfactory in hibernate?
What is the role of session interface in hibernate?
What is the need of hibernate tools when orm tools can be used?
What is transaction management in hibernate?
How to integrate Hibernate with Servlet or Struts2 web applications?