- All Known Implementing Classes:
For convenience, consider extending
of implementing this interface. This will prevent compilation errors in
future versions of jOOQ, when this interface might get new methods.
- Lukas Eder
inlineBindValuesForFieldComparisonsdefault boolean inlineBindValuesForFieldComparisons
(Field<?> field)[#5970] Inline all bind variables that are compared with the argument field.
In some cases, using a bind variable isn't the right choice when comparing a value with a
Field. This could be the case e.g. when:
- The field stems from a constant discriminator column in a view, e.g.
- The field statistics suggest there are only few possible values, with unequal distribution
- The field is an
ENUMor has a
CHECKconstraint (special case of the above)
In all of those cases, it may be more optimal to query
FIELD = 'x'rather than
FIELD = ?to help the optimiser use more accurate statistics for the specific inline value, rather than an average distribution assumption for a generic bind value.
Conditiontypes are affected by this transformation:
The feature can be activated using
field- The field for which bind values could be inlined.
- Whether bind value should be inlined.
- The field stems from a constant discriminator column in a view, e.g. in a