@Override
      protected List<Expression> visitArithmeticBinary(
          ArithmeticBinaryExpression node, Scope context) {
        List<Expression> leftResult = process(node.getLeft(), context);
        List<Expression> rightResult = process(node.getRight(), context);

        if (expandedExpressions == null) {
          // no Columns need to be expanded
          return Collections.singletonList(node);
        }

        ImmutableList.Builder<Expression> resultBuilder = new ImmutableList.Builder<>();
        int leftSize = leftResult.size();
        int rightSize = rightResult.size();
        int maxSize = Math.max(leftSize, rightSize);

        AtomicInteger baseIndex = new AtomicInteger(0);
        // if child is expanded, index of it reference the baseIndex, else the index of it always be
        // 0
        AtomicInteger leftIndex = (leftSize == maxSize) ? baseIndex : new AtomicInteger(0);
        AtomicInteger rightIndex = (rightSize == maxSize) ? baseIndex : new AtomicInteger(0);
        for (int i = 0; i < maxSize; i++) {
          resultBuilder.add(
              new ArithmeticBinaryExpression(
                  node.getOperator(),
                  leftResult.get(leftIndex.get()),
                  rightResult.get(rightIndex.get())));
          baseIndex.getAndIncrement();
        }

        return resultBuilder.build();
      }
Check if there is Columns function in expression, and verify they are same if there are multi
Column functions.

@param expression input expression
@return if there is Columns function in expression
@throws SemanticException if there are multi Columns functions but different
iotdb-core/datanode/src/main/java/org/apache/iotdb/db/queryengine/plan/relational/analyzer/StatementAnalyzer.java