for (int fieldIndex : fields) {
outputExpressionBuilder.add(new FieldOrExpression(fieldIndex));
}
}
else if (item instanceof SingleColumn) {
SingleColumn column = (SingleColumn) item;
ExpressionAnalysis expressionAnalysis = Analyzer.analyzeExpression(session, metadata, tupleDescriptor, analysis, context, column.getExpression());
analysis.addInPredicates(node, expressionAnalysis.getSubqueryInPredicates());
outputExpressionBuilder.add(new FieldOrExpression(column.getExpression()));
}
else {
throw new IllegalArgumentException("Unsupported SelectItem type: " + item.getClass().getName());
}
}