I have an unique constraint basically like this:
CREATE UNIQUE INDEX unique_value
ON user_configuration (value)
WHERE user_configuration.property = 4711;
But how it is possibly to do it dynamically ?
dsl.createTableIfNotExists(USER_CONFIGURATION).
.....
column(USER_CONFIGURATION.VALUE, SQLDataType.VARCHAR).
column(USER_CONFIGURATION.PROPERTY, SQLDataType.INTEGER).
constraints(
constraint("USER_CONFIGURATION. VALUE").unique( USER_CONFIGURATION. VALUE. XXXX )
).execute();
I would expect smthng like that
XXXX = USER_CONFIGURATION.PROPERTY.eq(4711)
but does not work
Postgresql 9.5 & JOOQ 3.9.1