private boolean hasAllSubExprWithConstOrPartColOrVirtualColWithOneTableAlias(ExprNodeDesc en) {
      if (!exprContainsOnlyPartitionColOrVirtualColOrConstants(en)) {
        return false;
      }

      Set<String> s = new HashSet<String>();
      Set<ExprNodeDesc> visited = new HashSet<ExprNodeDesc>();

      return getTableAliasHelper(en, s, visited);
    }
Check if the expression node satisfies the following :
Has all subexpressions containing constants or a partition/virtual column/coming from the
same table
@param en Expression Node Descriptor
@return true/false based on the condition specified in the above description.
ql/src/java/org/apache/hadoop/hive/ql/optimizer/PartitionColumnsSeparator.java