[jOOQ/jOOQ#14611] Make this work in Derby

inline((Object) null) may require a cast in some RDBMS, e.g. Derby. We
have to provide the field reference to the Param in order to be able to
cast the NULL literal properly.
This commit is contained in:
Lukas Eder 2023-02-13 17:30:07 +01:00
parent 38f2ccef8a
commit 3de4b0eff3

View File

@ -1497,7 +1497,7 @@ final class SelectQueryImpl<R extends Record> extends AbstractResultQuery<R> imp
&& !s.having.hasWhere()
&& !s.limit.isApplicable()
&& !s.hasUnions())
s.union((Select<R>) DSL.select(map(s.getSelect(), f -> inline((Object) null))).where(falseCondition()));
s.union((Select<R>) DSL.select(map(s.getSelect(), f -> inline((Object) null, f))).where(falseCondition()));
}));
else
accept0(ctx);