How does Hibernate distinguish between transient (i.e. newly instantiated) and detached objects?
Submitted by: Administrator" Hibernate uses the version property, if there is one.
" If not uses the identifier value. No identifier value means a new object. This does work only for Hibernate managed surrogate keys. Does not work for natural keys and assigned (i.e. not managed by Hibernate) surrogate keys.
" Write your own strategy with Interceptor.isUnsaved().
Submitted by: Administrator
" If not uses the identifier value. No identifier value means a new object. This does work only for Hibernate managed surrogate keys. Does not work for natural keys and assigned (i.e. not managed by Hibernate) surrogate keys.
" Write your own strategy with Interceptor.isUnsaved().
Submitted by: Administrator
Read Online Hibernate Job Interview Questions And Answers
Top Hibernate Questions
☺ | How does Hibernate distinguish between transient (i.e. newly instantiated) and detached objects? |
☺ | What is HQL? |
☺ | Why do you need ORM tools like hibernate? |
☺ | What does ORM consists of? |
☺ | What are the general considerations or best practices for defining your Hibernate persistent classes? |
Top Java Programming Language Categories
☺ | Core Java Interview Questions. |
☺ | Hibernate Interview Questions. |
☺ | Advanced Java Interview Questions. |
☺ | IBM WebSphere Interview Questions. |
☺ | Spring Framework Interview Questions. |