0

In JPA is simple to get the next value from DB with the @Generated etc.

In spring data JDBC working with autogenerated DB IDs is simple/natural.

But how about working with PKs/Ids that are not auto generated like in Oracle Sequence?

rkosegi
  • 14,165
  • 5
  • 50
  • 83
DanutClapa
  • 592
  • 2
  • 7
  • 23
  • Please explain more. Do you want to use a oracle sequence as primary key in your JPA entity ? – Shawrup Nov 21 '20 at 19:04
  • It is not JPA as you see, it is spring data JDBC. In JPA as I said in the question, it is simple. You add @Gnerated and problems solved. – DanutClapa Nov 21 '20 at 20:03

0 Answers0