Simplifying ANTI JOIN with jOOQ Syntax

ANTI JOIN is a very useful operator from relational algebra. Regrettably, only few dialects support it in terms of SQL syntax, as we've written earlier. In jOOQ, you can write it as follows: ctx.select(AUTHOR.ID) .from(AUTHOR) .leftAntiJoin(BOOK).on(BOOK.AUTHOR_ID.eq(AUTHOR.ID)) If your RDBMS supports this natively (e.g. ClickHouse, Databricks), then it is rendered as such. Otherwise, jOOQ will translate … Continue reading Simplifying ANTI JOIN with jOOQ Syntax