Is there way to define empty condition which produces nothing in output sql query? Now, for default condition I use trueCondition()
private static Condition limitCondition(Integer offset, Integer count) {
Condition limitCondition = trueCondition();
if (count != null && offset != null) {
limitCondition = rowNum.between(offset, count + offset);
} else if (count == null && offset != null) {
limitCondition = rowNum.greaterOrEqual(offset);
} else if (count != null && offset == null) {
limitCondition = rowNum.lessOrEqual(count);
}
return limitCondition;
}