When choosing from a table with a name userwith jOOQ, I get the following exception:
jOOQ; bad SQL grammar [insert into user (user_id, account_type) values (?, ?)]; nested exception is org.postgresql.util.PSQLException: ERROR: syntax error at or near "user"
My jOOQ settings:
private static final Settings jooqSettings = new Settings()
.withRenderSchema(false)
.withRenderNameStyle(RenderNameStyle.LOWER);
I create from it DSLContextand create a request in a transaction as follows:
ctx.insertInto(USER)
.set(USER.USER_ID, userId)
.set(USER.ACCOUNT_TYPE, "U")
.execute()
userimported as <jooq-generated-package>.tables.USER.
Does jOOQ have a config property to delete table names (all or just reserved keywords)? I could not find anything in the documents or source.
coudy source
share