How to make JOOQ generate both enum types and custom types?

I am using JOOQ-codegen 3.6.1.

When I generate my code it usually generates all Enum types fine. However JOOQ stops generating Enums when I add a custom type like so:

<customTypes> <customType> <name>LocalDateTime</name> <type>java.time.LocalDateTime</type> <converter>com.example.util.LocalDateTimeConverter</converter> </customType> </customTypes> <forcedTypes> <forcedType> <name>LocalDateTime</name> <types>TIMESTAMP</types> </forcedType> </forcedTypes>

The LocalDateTime data type is generated just fine in this case. I can't seem to find a way to generate both Enums and my custom data type.

It seems like JOOQ does not even detect Enums when there is a custom data type, as I get the log message:

INFO: Enums fetched : 0 (0 included, 0 excluded)

Any ideas?

-------------Problems Reply------------

I believe this is a bug in jOOQ, I reported it here:!topic/jooq-user/ENPvgqtVwW0

As a workaround you could avoid using <types> filter and always use <expression> filter to select the columns.

Category:java Views:7 Time:2018-06-13
Tags: mysql sql java jooq

Related post

Copyright (C), All Rights Reserved.

processed in 0.185 (s). 11 q(s)