Class SqlInternalOperators


public abstract class SqlInternalOperators extends Object
Contains internal operators.

These operators are always created directly, not by looking up a function or operator by name or syntax, and therefore this class does not implement interface SqlOperatorTable.

  • Field Details


      public static final SqlRowOperator ANONYMOUS_ROW
      Similar to SqlStdOperatorTable.ROW, but does not print "ROW".

      For arguments [1, TRUE], ROW would print "ROW (1, TRUE)", but this operator prints "(1, TRUE)".


      public static final SqlRowOperator ANONYMOUS_ROW_NO_PARENTHESES
      Similar to ANONYMOUS_ROW, but does not print "ROW" or parentheses.

      For arguments [1, TRUE], prints "1, TRUE". It is used in contexts where parentheses have been printed (because we thought we were about to print "(ROW (1, TRUE))") and we wish we had not.


      public static final SqlInternalOperator THROW_UNLESS
      "$THROW_UNLESS(condition, message)" throws an error with the given message if condition is not TRUE, otherwise returns TRUE.
    • DRUID_IN

      public static final SqlInOperator DRUID_IN
      An IN operator for Druid.

      Unlike the regular SqlStdOperatorTable.IN operator it may be used in RexCall. It does not require that its operands have consistent types.


      public static final SqlInOperator DRUID_NOT_IN
      A NOT IN operator for Druid, analogous to DRUID_IN.

      public static final SqlBetweenOperator DRUID_BETWEEN
      A BETWEEN operator for Druid, analogous to DRUID_IN.

      public static final SqlOperator SEPARATOR
      Separator expression inside GROUP_CONCAT, e.g. 'SEPARATOR ',''.

      public static final SqlInternalOperator GROUP_BY_DISTINCT
      DISTINCT operator, occurs within GROUP BY clause.
    • FETCH

      public static final SqlOperator FETCH
      Fetch operator is ONLY used for its precedence during unparsing.

      public static final SqlDatetimeSubtractionOperator MINUS_DATE2
      2-argument form of the special minus-date operator to be used with BigQuery subtraction functions. It differs from the standard MINUS_DATE operator in that it has 2 arguments, and subtracts an interval from a datetime.
    • OFFSET

      public static final SqlOperator OFFSET
      Offset operator is ONLY used for its precedence during unparsing.

      public static final SqlAggFunction LITERAL_AGG
      Aggregate function that always returns a given literal.