//criteria cannot be pushed out of a full outer join clause
if (joinType == JoinType.JOIN_FULL_OUTER || joinType == JoinType.JOIN_CROSS) {
continue;
}
Iterator crits = criteria.iterator();
while (crits.hasNext()) {
Criteria crit = (Criteria)crits.next();
//special case handling for true/false criteria
if (crit.equals(QueryRewriter.FALSE_CRITERIA) || crit.equals(QueryRewriter.UNKNOWN_CRITERIA)) {
if (joinType == JoinType.JOIN_INNER) {
FrameUtil.replaceWithNullNode(node);
} else {
//must be a left or right outer join, replace the inner side with null
FrameUtil.replaceWithNullNode(JoinUtil.getInnerSideJoinNodes(node)[0]);
removeCopiedFlag = true;
}
//since a null node has been created, raise it to its highest point
pushRuleRaiseNull = true;
treeChanged = true;
break;
} else if (crit.equals(QueryRewriter.TRUE_CRITERIA)) {
crits.remove();
break;
}
if (pushCriteria(node, crit)) {
treeChanged = true;
crits.remove();
}
}
//degrade the join if there is no criteria left
if (criteria.isEmpty() && joinType == JoinType.JOIN_INNER) {