On Wed, May 29, 2024 at 12:04 PM Giovanni Zotta <
[email protected]> wrote:

> Thanks all for the replies, very useful! I think getting the IDs on the
> client and then using COPY makes sense, and sounds like the best
> alternative.
>
> The problem I have now is that I don't have an explicit sequence, but
> simply a serial value: `id bigserial primary key`, so I do not have a
> generates `Sequence` object in java. I tried adding the configuration
> suggested here
> <https://www.jooq.org/doc/latest/manual/code-generation/codegen-sequences/>,
> but only my explicitly created sequences (via explicit `CREATE SEQUENCE`)
> are generated, and not the primary key serial I'm interested in.
>

Serials are implemented using sequences in PostgreSQL. For convenience,
jOOQ hides these by default (because you usually don't need them). You can
re-enable them using includeSystemSequences
https://www.jooq.org/doc/latest/manual/code-generation/codegen-advanced/codegen-config-database/codegen-database-include-object-types/

I hope this helps

-- 
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 [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jooq-user/CAB4ELO5ERU8%3Dd5-8LTqzNvoTsKjj%3DguP3aSZrY7b4h7KuqaN_Q%40mail.gmail.com.

Reply via email to