That's a really interesting question, and the best answer is: You have to write this manually. The SQL/JDBC/jOOQ layer can only generate system exceptions, like a constraint violation exception in this case. But there are many different types of constraints, and many different things that a constraint violation can mean. Only you and your service layer can possibly know how to translate such a violation to a meaningful (localised?) user error message.
Having said so, you could hook in an ExecuteListener into jOOQ to handle errors in a single location:
https://www.jooq.org/javadoc/latest/org/jooq/ExecuteListener...
An example that uses the Spring Exception translator:
https://github.com/jOOQ/jOOQ/blob/master/jOOQ-examples/jOOQ-...