Typesafe embedded DSLs like jOOQ are extremely powerful for dynamic SQL, because the query you're constructing with the jOOQ DSL is a dynamic query by nature. You're constructing a query expression tree using a convenient API (the "DSL"), even if you think your SQL statement is static. For instance: for (Record rec : ctx.select(ACTOR.FIRST_NAME, ACTOR.LAST_NAME) … Continue reading A Functional Programming Approach to Dynamic SQL with jOOQ