Available in versions: Dev (3.21) | Latest (3.20) | 3.19 | 3.18 | 3.17 | 3.16 | 3.15 | 3.14 | 3.13 | 3.12 | 3.11
Client-side aliased tables
Supported by ✅ Open Source Edition ✅ Express Edition ✅ Professional Edition ✅ Enterprise Edition
Table expressions can be "aliased" in your Java code only, without any effect on generated SQL. This can greatly help improve readability of your jOOQ query, without running into the occasional edge case when a table is aliased in SQL, e.g. when working with DML statements that may have poor aliasing support in some dialects.
-- No aliasing done in SQL SELECT BOOK.ID FROM BOOK;
Book b = BOOK; create.select(b.ID).from(b).fetch();
This is just a special case illustrating that every jOOQ query is a dynamic SQL query, even if it doesn't necessarily look this way.
Feedback
Do you have any feedback about this page? We'd love to hear it!