// then sql evaluation is not possible.
int countNonNativeInputArg = 0;
for (CrossJoinArg arg : cjArgs) {
if (arg instanceof MemberListCrossJoinArg) {
MemberListCrossJoinArg cjArg =
(MemberListCrossJoinArg)arg;
if (cjArg.hasAllMember() || cjArg.isEmptyCrossJoinArg()) {
++countNonNativeInputArg;
}
if (cjArg.hasCalcMembers()) {
countNonNativeInputArg = cjArgs.length;
break;
}
}
}
if (countNonNativeInputArg == cjArgs.length) {
// If all inputs contain "All" members; or
// if all inputs are MemberListCrossJoinArg with empty member list
// content, then native evaluation is not feasible.
alertCrossJoinNonNative(
evaluator,
fun,
"either all arguments contain the ALL member, "
+ "or empty member lists, or one has a calculated member");
return null;
}
if (isPreferInterpreter(cjArgs, true)) {
// Native evaluation wouldn't buy us anything, so no
// need to alert
return null;
}
// Verify that args are valid
List<RolapLevel> levels = new ArrayList<RolapLevel>();
for (CrossJoinArg cjArg : cjArgs) {
RolapLevel level = cjArg.getLevel();
if (level != null) {
// Only add non null levels. These levels have real
// constraints.
levels.add(level);
}