How to use existing Oracle sequence to generate id in hibernate?

后端 未结 10 1102
夕颜
夕颜 2020-12-04 19:53

I have legacy Oracle db with a sequence named PRODUCT_ID_SEQ.

Here is the mapping of Product class for which I need generate correct ids:<

10条回答
  •  天涯浪人
    2020-12-04 20:18


    By default Hibernate uses sequence HiLo generator which ,unless you have special needs, it is good (performance wise). You can read more of that in my blog here

    Eyal

提交回复
热议问题