How to create an auto incremented column?

8 views
Skip to first unread message

joseph...@gmail.com

unread,
May 26, 2016, 4:51:47 PM5/26/16
to jOOQ User Group
Hi

I would like to create a table having a column with an auto incremented value, the way mysql does so for example.

I haven't found a way to do it, am I missing something?

Thanks in advance

Best
joseph

Lukas Eder

unread,
May 27, 2016, 2:48:19 AM5/27/16
to jooq...@googlegroups.com
This is, unfortunately, not yet implemented:

This can currently not be emulated by plain SQL. The only workaround I see right now is to implement an ExecuteListener (or VisitListener) that patches the generated SQL code.

Hope this helps,
Lukas

--
You received this message because you are subscribed to the Google Groups "jOOQ User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jooq-user+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

joseph...@gmail.com

unread,
May 27, 2016, 6:06:11 AM5/27/16
to jOOQ User Group
Thanks for the answer, let's see how this issues evolves.

The current workaround is to handle this on my own, through a dedicated table and transactions. Not as efficient but quite enough for now ;)

++
Reply all
Reply to author
Forward
0 new messages