sqlglot.dialects.clickhouse API documentation

Edit on GitHub

# sqlglot.dialects.clickhouse

View Source

      1from __future__ import annotations
      2
      3import typing as t
      4
      5from sqlglot import exp, generator, parser, tokens, transforms
      6from sqlglot.dialects.dialect import (
      7    Dialect,
      8    arg_max_or_min_no_count,
      9    build_formatted_time,
     10    date_delta_sql,
     11    inline_array_sql,
     12    json_extract_segments,
     13    json_path_key_only_name,
     14    no_pivot_sql,
     15    build_json_extract_path,
     16    rename_func,
     17    var_map_sql,
     18)
     19from sqlglot.helper import is_int, seq_get
     20from sqlglot.tokens import Token, TokenType
     21
     22
     23def _build_date_format(args: t.List) -> exp.TimeToStr:
     24    expr = build_formatted_time(exp.TimeToStr, "clickhouse")(args)
     25
     26    timezone = seq_get(args, 2)
     27    if timezone:
     28        expr.set("timezone", timezone)
     29
     30    return expr
     31
     32
     33def _lower_func(sql: str) -> str:
     34    index = sql.index("(")
     35    return sql[:index].lower() + sql[index:]
     36
     37
     38def _quantile_sql(self: ClickHouse.Generator, expression: exp.Quantile) -> str:
     39    quantile = expression.args["quantile"]
     40    args = f"({self.sql(expression, 'this')})"
     41
     42    if isinstance(quantile, exp.Array):
     43        func = self.func("quantiles", *quantile)
     44    else:
     45        func = self.func("quantile", quantile)
     46
     47    return func + args
     48
     49
     50def _build_count_if(args: t.List) -> exp.CountIf | exp.CombinedAggFunc:
     51    if len(args) == 1:
     52        return exp.CountIf(this=seq_get(args, 0))
     53
     54    return exp.CombinedAggFunc(this="countIf", expressions=args, parts=("count", "If"))
     55
     56
     57class ClickHouse(Dialect):
     58    NORMALIZE_FUNCTIONS: bool | str = False
     59    NULL_ORDERING = "nulls_are_last"
     60    SUPPORTS_USER_DEFINED_TYPES = False
     61    SAFE_DIVISION = True
     62    LOG_BASE_FIRST: t.Optional[bool] = None
     63
     64    UNESCAPED_SEQUENCES = {
     65        "\\0": "\0",
     66    }
     67
     68    class Tokenizer(tokens.Tokenizer):
     69        COMMENTS = ["--", "#", "#!", ("/*", "*/")]
     70        IDENTIFIERS = ['"', "`"]
     71        STRING_ESCAPES = ["'", "\\"]
     72        BIT_STRINGS = [("0b", "")]
     73        HEX_STRINGS = [("0x", ""), ("0X", "")]
     74        HEREDOC_STRINGS = ["$"]
     75
     76        KEYWORDS = {
     77            **tokens.Tokenizer.KEYWORDS,
     78            "ATTACH": TokenType.COMMAND,
     79            "DATE32": TokenType.DATE32,
     80            "DATETIME64": TokenType.DATETIME64,
     81            "DICTIONARY": TokenType.DICTIONARY,
     82            "ENUM8": TokenType.ENUM8,
     83            "ENUM16": TokenType.ENUM16,
     84            "FINAL": TokenType.FINAL,
     85            "FIXEDSTRING": TokenType.FIXEDSTRING,
     86            "FLOAT32": TokenType.FLOAT,
     87            "FLOAT64": TokenType.DOUBLE,
     88            "GLOBAL": TokenType.GLOBAL,
     89            "INT256": TokenType.INT256,
     90            "LOWCARDINALITY": TokenType.LOWCARDINALITY,
     91            "MAP": TokenType.MAP,
     92            "NESTED": TokenType.NESTED,
     93            "SAMPLE": TokenType.TABLE_SAMPLE,
     94            "TUPLE": TokenType.STRUCT,
     95            "UINT128": TokenType.UINT128,
     96            "UINT16": TokenType.USMALLINT,
     97            "UINT256": TokenType.UINT256,
     98            "UINT32": TokenType.UINT,
     99            "UINT64": TokenType.UBIGINT,
    100            "UINT8": TokenType.UTINYINT,
    101            "IPV4": TokenType.IPV4,
    102            "IPV6": TokenType.IPV6,
    103            "AGGREGATEFUNCTION": TokenType.AGGREGATEFUNCTION,
    104            "SIMPLEAGGREGATEFUNCTION": TokenType.SIMPLEAGGREGATEFUNCTION,
    105            "SYSTEM": TokenType.COMMAND,
    106            "PREWHERE": TokenType.PREWHERE,
    107        }
    108
    109        SINGLE_TOKENS = {
    110            **tokens.Tokenizer.SINGLE_TOKENS,
    111            "$": TokenType.HEREDOC_STRING,
    112        }
    113
    114    class Parser(parser.Parser):
    115        # Tested in ClickHouse's playground, it seems that the following two queries do the same thing
    116        # * select x from t1 union all select x from t2 limit 1;
    117        # * select x from t1 union all (select x from t2 limit 1);
    118        MODIFIERS_ATTACHED_TO_UNION = False
    119        INTERVAL_SPANS = False
    120
    121        FUNCTIONS = {
    122            **parser.Parser.FUNCTIONS,
    123            "ANY": exp.AnyValue.from_arg_list,
    124            "ARRAYSUM": exp.ArraySum.from_arg_list,
    125            "COUNTIF": _build_count_if,
    126            "DATE_ADD": lambda args: exp.DateAdd(
    127                this=seq_get(args, 2), expression=seq_get(args, 1), unit=seq_get(args, 0)
    128            ),
    129            "DATEADD": lambda args: exp.DateAdd(
    130                this=seq_get(args, 2), expression=seq_get(args, 1), unit=seq_get(args, 0)
    131            ),
    132            "DATE_DIFF": lambda args: exp.DateDiff(
    133                this=seq_get(args, 2), expression=seq_get(args, 1), unit=seq_get(args, 0)
    134            ),
    135            "DATEDIFF": lambda args: exp.DateDiff(
    136                this=seq_get(args, 2), expression=seq_get(args, 1), unit=seq_get(args, 0)
    137            ),
    138            "DATE_FORMAT": _build_date_format,
    139            "FORMATDATETIME": _build_date_format,
    140            "JSONEXTRACTSTRING": build_json_extract_path(
    141                exp.JSONExtractScalar, zero_based_indexing=False
    142            ),
    143            "MAP": parser.build_var_map,
    144            "MATCH": exp.RegexpLike.from_arg_list,
    145            "RANDCANONICAL": exp.Rand.from_arg_list,
    146            "TUPLE": exp.Struct.from_arg_list,
    147            "UNIQ": exp.ApproxDistinct.from_arg_list,
    148            "XOR": lambda args: exp.Xor(expressions=args),
    149        }
    150
    151        AGG_FUNCTIONS = {
    152            "count",
    153            "min",
    154            "max",
    155            "sum",
    156            "avg",
    157            "any",
    158            "stddevPop",
    159            "stddevSamp",
    160            "varPop",
    161            "varSamp",
    162            "corr",
    163            "covarPop",
    164            "covarSamp",
    165            "entropy",
    166            "exponentialMovingAverage",
    167            "intervalLengthSum",
    168            "kolmogorovSmirnovTest",
    169            "mannWhitneyUTest",
    170            "median",
    171            "rankCorr",
    172            "sumKahan",
    173            "studentTTest",
    174            "welchTTest",
    175            "anyHeavy",
    176            "anyLast",
    177            "boundingRatio",
    178            "first_value",
    179            "last_value",
    180            "argMin",
    181            "argMax",
    182            "avgWeighted",
    183            "topK",
    184            "topKWeighted",
    185            "deltaSum",
    186            "deltaSumTimestamp",
    187            "groupArray",
    188            "groupArrayLast",
    189            "groupUniqArray",
    190            "groupArrayInsertAt",
    191            "groupArrayMovingAvg",
    192            "groupArrayMovingSum",
    193            "groupArraySample",
    194            "groupBitAnd",
    195            "groupBitOr",
    196            "groupBitXor",
    197            "groupBitmap",
    198            "groupBitmapAnd",
    199            "groupBitmapOr",
    200            "groupBitmapXor",
    201            "sumWithOverflow",
    202            "sumMap",
    203            "minMap",
    204            "maxMap",
    205            "skewSamp",
    206            "skewPop",
    207            "kurtSamp",
    208            "kurtPop",
    209            "uniq",
    210            "uniqExact",
    211            "uniqCombined",
    212            "uniqCombined64",
    213            "uniqHLL12",
    214            "uniqTheta",
    215            "quantile",
    216            "quantiles",
    217            "quantileExact",
    218            "quantilesExact",
    219            "quantileExactLow",
    220            "quantilesExactLow",
    221            "quantileExactHigh",
    222            "quantilesExactHigh",
    223            "quantileExactWeighted",
    224            "quantilesExactWeighted",
    225            "quantileTiming",
    226            "quantilesTiming",
    227            "quantileTimingWeighted",
    228            "quantilesTimingWeighted",
    229            "quantileDeterministic",
    230            "quantilesDeterministic",
    231            "quantileTDigest",
    232            "quantilesTDigest",
    233            "quantileTDigestWeighted",
    234            "quantilesTDigestWeighted",
    235            "quantileBFloat16",
    236            "quantilesBFloat16",
    237            "quantileBFloat16Weighted",
    238            "quantilesBFloat16Weighted",
    239            "simpleLinearRegression",
    240            "stochasticLinearRegression",
    241            "stochasticLogisticRegression",
    242            "categoricalInformationValue",
    243            "contingency",
    244            "cramersV",
    245            "cramersVBiasCorrected",
    246            "theilsU",
    247            "maxIntersections",
    248            "maxIntersectionsPosition",
    249            "meanZTest",
    250            "quantileInterpolatedWeighted",
    251            "quantilesInterpolatedWeighted",
    252            "quantileGK",
    253            "quantilesGK",
    254            "sparkBar",
    255            "sumCount",
    256            "largestTriangleThreeBuckets",
    257            "histogram",
    258            "sequenceMatch",
    259            "sequenceCount",
    260            "windowFunnel",
    261            "retention",
    262            "uniqUpTo",
    263            "sequenceNextNode",
    264            "exponentialTimeDecayedAvg",
    265        }
    266
    267        AGG_FUNCTIONS_SUFFIXES = [
    268            "If",
    269            "Array",
    270            "ArrayIf",
    271            "Map",
    272            "SimpleState",
    273            "State",
    274            "Merge",
    275            "MergeState",
    276            "ForEach",
    277            "Distinct",
    278            "OrDefault",
    279            "OrNull",
    280            "Resample",
    281            "ArgMin",
    282            "ArgMax",
    283        ]
    284
    285        FUNC_TOKENS = {
    286            *parser.Parser.FUNC_TOKENS,
    287            TokenType.SET,
    288        }
    289
    290        AGG_FUNC_MAPPING = (
    291            lambda functions, suffixes: {
    292                f"{f}{sfx}": (f, sfx) for sfx in (suffixes + [""]) for f in functions
    293            }
    294        )(AGG_FUNCTIONS, AGG_FUNCTIONS_SUFFIXES)
    295
    296        FUNCTIONS_WITH_ALIASED_ARGS = {*parser.Parser.FUNCTIONS_WITH_ALIASED_ARGS, "TUPLE"}
    297
    298        FUNCTION_PARSERS = {
    299            **parser.Parser.FUNCTION_PARSERS,
    300            "ARRAYJOIN": lambda self: self.expression(exp.Explode, this=self._parse_expression()),
    301            "QUANTILE": lambda self: self._parse_quantile(),
    302        }
    303
    304        FUNCTION_PARSERS.pop("MATCH")
    305
    306        NO_PAREN_FUNCTION_PARSERS = parser.Parser.NO_PAREN_FUNCTION_PARSERS.copy()
    307        NO_PAREN_FUNCTION_PARSERS.pop("ANY")
    308
    309        RANGE_PARSERS = {
    310            **parser.Parser.RANGE_PARSERS,
    311            TokenType.GLOBAL: lambda self, this: self._match(TokenType.IN)
    312            and self._parse_in(this, is_global=True),
    313        }
    314
    315        # The PLACEHOLDER entry is popped because 1) it doesn't affect Clickhouse (it corresponds to
    316        # the postgres-specific JSONBContains parser) and 2) it makes parsing the ternary op simpler.
    317        COLUMN_OPERATORS = parser.Parser.COLUMN_OPERATORS.copy()
    318        COLUMN_OPERATORS.pop(TokenType.PLACEHOLDER)
    319
    320        JOIN_KINDS = {
    321            *parser.Parser.JOIN_KINDS,
    322            TokenType.ANY,
    323            TokenType.ASOF,
    324            TokenType.ARRAY,
    325        }
    326
    327        TABLE_ALIAS_TOKENS = parser.Parser.TABLE_ALIAS_TOKENS - {
    328            TokenType.ANY,
    329            TokenType.ARRAY,
    330            TokenType.FINAL,
    331            TokenType.FORMAT,
    332            TokenType.SETTINGS,
    333        }
    334
    335        ALIAS_TOKENS = parser.Parser.ALIAS_TOKENS - {
    336            TokenType.FORMAT,
    337        }
    338
    339        LOG_DEFAULTS_TO_LN = True
    340
    341        QUERY_MODIFIER_PARSERS = {
    342            **parser.Parser.QUERY_MODIFIER_PARSERS,
    343            TokenType.SETTINGS: lambda self: (
    344                "settings",
    345                self._advance() or self._parse_csv(self._parse_conjunction),
    346            ),
    347            TokenType.FORMAT: lambda self: ("format", self._advance() or self._parse_id_var()),
    348        }
    349
    350        CONSTRAINT_PARSERS = {
    351            **parser.Parser.CONSTRAINT_PARSERS,
    352            "INDEX": lambda self: self._parse_index_constraint(),
    353            "CODEC": lambda self: self._parse_compress(),
    354        }
    355
    356        SCHEMA_UNNAMED_CONSTRAINTS = {
    357            *parser.Parser.SCHEMA_UNNAMED_CONSTRAINTS,
    358            "INDEX",
    359        }
    360
    361        def _parse_conjunction(self) -> t.Optional[exp.Expression]:
    362            this = super()._parse_conjunction()
    363
    364            if self._match(TokenType.PLACEHOLDER):
    365                return self.expression(
    366                    exp.If,
    367                    this=this,
    368                    true=self._parse_conjunction(),
    369                    false=self._match(TokenType.COLON) and self._parse_conjunction(),
    370                )
    371
    372            return this
    373
    374        def _parse_placeholder(self) -> t.Optional[exp.Expression]:
    375            """
    376            Parse a placeholder expression like SELECT {abc: UInt32} or FROM {table: Identifier}
    377            https://clickhouse.com/docs/en/sql-reference/syntax#defining-and-using-query-parameters
    378            """
    379            if not self._match(TokenType.L_BRACE):
    380                return None
    381
    382            this = self._parse_id_var()
    383            self._match(TokenType.COLON)
    384            kind = self._parse_types(check_func=False, allow_identifiers=False) or (
    385                self._match_text_seq("IDENTIFIER") and "Identifier"
    386            )
    387
    388            if not kind:
    389                self.raise_error("Expecting a placeholder type or 'Identifier' for tables")
    390            elif not self._match(TokenType.R_BRACE):
    391                self.raise_error("Expecting }")
    392
    393            return self.expression(exp.Placeholder, this=this, kind=kind)
    394
    395        def _parse_in(self, this: t.Optional[exp.Expression], is_global: bool = False) -> exp.In:
    396            this = super()._parse_in(this)
    397            this.set("is_global", is_global)
    398            return this
    399
    400        def _parse_table(
    401            self,
    402            schema: bool = False,
    403            joins: bool = False,
    404            alias_tokens: t.Optional[t.Collection[TokenType]] = None,
    405            parse_bracket: bool = False,
    406            is_db_reference: bool = False,
    407            parse_partition: bool = False,
    408        ) -> t.Optional[exp.Expression]:
    409            this = super()._parse_table(
    410                schema=schema,
    411                joins=joins,
    412                alias_tokens=alias_tokens,
    413                parse_bracket=parse_bracket,
    414                is_db_reference=is_db_reference,
    415            )
    416
    417            if self._match(TokenType.FINAL):
    418                this = self.expression(exp.Final, this=this)
    419
    420            return this
    421
    422        def _parse_position(self, haystack_first: bool = False) -> exp.StrPosition:
    423            return super()._parse_position(haystack_first=True)
    424
    425        # https://clickhouse.com/docs/en/sql-reference/statements/select/with/
    426        def _parse_cte(self) -> exp.CTE:
    427            # WITH <identifier> AS <subquery expression>
    428            cte: t.Optional[exp.CTE] = self._try_parse(super()._parse_cte)
    429
    430            if not cte:
    431                # WITH <expression> AS <identifier>
    432                cte = self.expression(
    433                    exp.CTE,
    434                    this=self._parse_conjunction(),
    435                    alias=self._parse_table_alias(),
    436                    scalar=True,
    437                )
    438
    439            return cte
    440
    441        def _parse_join_parts(
    442            self,
    443        ) -> t.Tuple[t.Optional[Token], t.Optional[Token], t.Optional[Token]]:
    444            is_global = self._match(TokenType.GLOBAL) and self._prev
    445            kind_pre = self._match_set(self.JOIN_KINDS, advance=False) and self._prev
    446
    447            if kind_pre:
    448                kind = self._match_set(self.JOIN_KINDS) and self._prev
    449                side = self._match_set(self.JOIN_SIDES) and self._prev
    450                return is_global, side, kind
    451
    452            return (
    453                is_global,
    454                self._match_set(self.JOIN_SIDES) and self._prev,
    455                self._match_set(self.JOIN_KINDS) and self._prev,
    456            )
    457
    458        def _parse_join(
    459            self, skip_join_token: bool = False, parse_bracket: bool = False
    460        ) -> t.Optional[exp.Join]:
    461            join = super()._parse_join(skip_join_token=skip_join_token, parse_bracket=True)
    462            if join:
    463                join.set("global", join.args.pop("method", None))
    464
    465            return join
    466
    467        def _parse_function(
    468            self,
    469            functions: t.Optional[t.Dict[str, t.Callable]] = None,
    470            anonymous: bool = False,
    471            optional_parens: bool = True,
    472            any_token: bool = False,
    473        ) -> t.Optional[exp.Expression]:
    474            expr = super()._parse_function(
    475                functions=functions,
    476                anonymous=anonymous,
    477                optional_parens=optional_parens,
    478                any_token=any_token,
    479            )
    480
    481            func = expr.this if isinstance(expr, exp.Window) else expr
    482
    483            # Aggregate functions can be split in 2 parts: <func_name><suffix>
    484            parts = (
    485                self.AGG_FUNC_MAPPING.get(func.this) if isinstance(func, exp.Anonymous) else None
    486            )
    487
    488            if parts:
    489                params = self._parse_func_params(func)
    490
    491                kwargs = {
    492                    "this": func.this,
    493                    "expressions": func.expressions,
    494                }
    495                if parts[1]:
    496                    kwargs["parts"] = parts
    497                    exp_class = exp.CombinedParameterizedAgg if params else exp.CombinedAggFunc
    498                else:
    499                    exp_class = exp.ParameterizedAgg if params else exp.AnonymousAggFunc
    500
    501                kwargs["exp_class"] = exp_class
    502                if params:
    503                    kwargs["params"] = params
    504
    505                func = self.expression(**kwargs)
    506
    507                if isinstance(expr, exp.Window):
    508                    # The window's func was parsed as Anonymous in base parser, fix its
    509                    # type to be CH style CombinedAnonymousAggFunc / AnonymousAggFunc
    510                    expr.set("this", func)
    511                elif params:
    512                    # Params have blocked super()._parse_function() from parsing the following window
    513                    # (if that exists) as they're standing between the function call and the window spec
    514                    expr = self._parse_window(func)
    515                else:
    516                    expr = func
    517
    518            return expr
    519
    520        def _parse_func_params(
    521            self, this: t.Optional[exp.Func] = None
    522        ) -> t.Optional[t.List[exp.Expression]]:
    523            if self._match_pair(TokenType.R_PAREN, TokenType.L_PAREN):
    524                return self._parse_csv(self._parse_lambda)
    525
    526            if self._match(TokenType.L_PAREN):
    527                params = self._parse_csv(self._parse_lambda)
    528                self._match_r_paren(this)
    529                return params
    530
    531            return None
    532
    533        def _parse_quantile(self) -> exp.Quantile:
    534            this = self._parse_lambda()
    535            params = self._parse_func_params()
    536            if params:
    537                return self.expression(exp.Quantile, this=params[0], quantile=this)
    538            return self.expression(exp.Quantile, this=this, quantile=exp.Literal.number(0.5))
    539
    540        def _parse_wrapped_id_vars(self, optional: bool = False) -> t.List[exp.Expression]:
    541            return super()._parse_wrapped_id_vars(optional=True)
    542
    543        def _parse_primary_key(
    544            self, wrapped_optional: bool = False, in_props: bool = False
    545        ) -> exp.PrimaryKeyColumnConstraint | exp.PrimaryKey:
    546            return super()._parse_primary_key(
    547                wrapped_optional=wrapped_optional or in_props, in_props=in_props
    548            )
    549
    550        def _parse_on_property(self) -> t.Optional[exp.Expression]:
    551            index = self._index
    552            if self._match_text_seq("CLUSTER"):
    553                this = self._parse_id_var()
    554                if this:
    555                    return self.expression(exp.OnCluster, this=this)
    556                else:
    557                    self._retreat(index)
    558            return None
    559
    560        def _parse_index_constraint(
    561            self, kind: t.Optional[str] = None
    562        ) -> exp.IndexColumnConstraint:
    563            # INDEX name1 expr TYPE type1(args) GRANULARITY value
    564            this = self._parse_id_var()
    565            expression = self._parse_conjunction()
    566
    567            index_type = self._match_text_seq("TYPE") and (
    568                self._parse_function() or self._parse_var()
    569            )
    570
    571            granularity = self._match_text_seq("GRANULARITY") and self._parse_term()
    572
    573            return self.expression(
    574                exp.IndexColumnConstraint,
    575                this=this,
    576                expression=expression,
    577                index_type=index_type,
    578                granularity=granularity,
    579            )
    580
    581    class Generator(generator.Generator):
    582        QUERY_HINTS = False
    583        STRUCT_DELIMITER = ("(", ")")
    584        NVL2_SUPPORTED = False
    585        TABLESAMPLE_REQUIRES_PARENS = False
    586        TABLESAMPLE_SIZE_IS_ROWS = False
    587        TABLESAMPLE_KEYWORDS = "SAMPLE"
    588        LAST_DAY_SUPPORTS_DATE_PART = False
    589        CAN_IMPLEMENT_ARRAY_ANY = True
    590        SUPPORTS_TO_NUMBER = False
    591
    592        STRING_TYPE_MAPPING = {
    593            exp.DataType.Type.CHAR: "String",
    594            exp.DataType.Type.LONGBLOB: "String",
    595            exp.DataType.Type.LONGTEXT: "String",
    596            exp.DataType.Type.MEDIUMBLOB: "String",
    597            exp.DataType.Type.MEDIUMTEXT: "String",
    598            exp.DataType.Type.TINYBLOB: "String",
    599            exp.DataType.Type.TINYTEXT: "String",
    600            exp.DataType.Type.TEXT: "String",
    601            exp.DataType.Type.VARBINARY: "String",
    602            exp.DataType.Type.VARCHAR: "String",
    603        }
    604
    605        SUPPORTED_JSON_PATH_PARTS = {
    606            exp.JSONPathKey,
    607            exp.JSONPathRoot,
    608            exp.JSONPathSubscript,
    609        }
    610
    611        TYPE_MAPPING = {
    612            **generator.Generator.TYPE_MAPPING,
    613            **STRING_TYPE_MAPPING,
    614            exp.DataType.Type.ARRAY: "Array",
    615            exp.DataType.Type.BIGINT: "Int64",
    616            exp.DataType.Type.DATE32: "Date32",
    617            exp.DataType.Type.DATETIME64: "DateTime64",
    618            exp.DataType.Type.DOUBLE: "Float64",
    619            exp.DataType.Type.ENUM: "Enum",
    620            exp.DataType.Type.ENUM8: "Enum8",
    621            exp.DataType.Type.ENUM16: "Enum16",
    622            exp.DataType.Type.FIXEDSTRING: "FixedString",
    623            exp.DataType.Type.FLOAT: "Float32",
    624            exp.DataType.Type.INT: "Int32",
    625            exp.DataType.Type.MEDIUMINT: "Int32",
    626            exp.DataType.Type.INT128: "Int128",
    627            exp.DataType.Type.INT256: "Int256",
    628            exp.DataType.Type.LOWCARDINALITY: "LowCardinality",
    629            exp.DataType.Type.MAP: "Map",
    630            exp.DataType.Type.NESTED: "Nested",
    631            exp.DataType.Type.NULLABLE: "Nullable",
    632            exp.DataType.Type.SMALLINT: "Int16",
    633            exp.DataType.Type.STRUCT: "Tuple",
    634            exp.DataType.Type.TINYINT: "Int8",
    635            exp.DataType.Type.UBIGINT: "UInt64",
    636            exp.DataType.Type.UINT: "UInt32",
    637            exp.DataType.Type.UINT128: "UInt128",
    638            exp.DataType.Type.UINT256: "UInt256",
    639            exp.DataType.Type.USMALLINT: "UInt16",
    640            exp.DataType.Type.UTINYINT: "UInt8",
    641            exp.DataType.Type.IPV4: "IPv4",
    642            exp.DataType.Type.IPV6: "IPv6",
    643            exp.DataType.Type.AGGREGATEFUNCTION: "AggregateFunction",
    644            exp.DataType.Type.SIMPLEAGGREGATEFUNCTION: "SimpleAggregateFunction",
    645        }
    646
    647        TRANSFORMS = {
    648            **generator.Generator.TRANSFORMS,
    649            exp.AnyValue: rename_func("any"),
    650            exp.ApproxDistinct: rename_func("uniq"),
    651            exp.ArrayFilter: lambda self, e: self.func("arrayFilter", e.expression, e.this),
    652            exp.ArraySize: rename_func("LENGTH"),
    653            exp.ArraySum: rename_func("arraySum"),
    654            exp.ArgMax: arg_max_or_min_no_count("argMax"),
    655            exp.ArgMin: arg_max_or_min_no_count("argMin"),
    656            exp.Array: inline_array_sql,
    657            exp.CastToStrType: rename_func("CAST"),
    658            exp.CountIf: rename_func("countIf"),
    659            exp.CompressColumnConstraint: lambda self,
    660            e: f"CODEC({self.expressions(e, key='this', flat=True)})",
    661            exp.ComputedColumnConstraint: lambda self,
    662            e: f"{'MATERIALIZED' if e.args.get('persisted') else 'ALIAS'} {self.sql(e, 'this')}",
    663            exp.CurrentDate: lambda self, e: self.func("CURRENT_DATE"),
    664            exp.DateAdd: date_delta_sql("DATE_ADD"),
    665            exp.DateDiff: date_delta_sql("DATE_DIFF"),
    666            exp.Explode: rename_func("arrayJoin"),
    667            exp.Final: lambda self, e: f"{self.sql(e, 'this')} FINAL",
    668            exp.IsNan: rename_func("isNaN"),
    669            exp.JSONExtract: json_extract_segments("JSONExtractString", quoted_index=False),
    670            exp.JSONExtractScalar: json_extract_segments("JSONExtractString", quoted_index=False),
    671            exp.JSONPathKey: json_path_key_only_name,
    672            exp.JSONPathRoot: lambda *_: "",
    673            exp.Map: lambda self, e: _lower_func(var_map_sql(self, e)),
    674            exp.Nullif: rename_func("nullIf"),
    675            exp.PartitionedByProperty: lambda self, e: f"PARTITION BY {self.sql(e, 'this')}",
    676            exp.Pivot: no_pivot_sql,
    677            exp.Quantile: _quantile_sql,
    678            exp.RegexpLike: lambda self, e: self.func("match", e.this, e.expression),
    679            exp.Rand: rename_func("randCanonical"),
    680            exp.Select: transforms.preprocess([transforms.eliminate_qualify]),
    681            exp.StartsWith: rename_func("startsWith"),
    682            exp.StrPosition: lambda self, e: self.func(
    683                "position", e.this, e.args.get("substr"), e.args.get("position")
    684            ),
    685            exp.TimeToStr: lambda self, e: self.func(
    686                "DATE_FORMAT", e.this, self.format_time(e), e.args.get("timezone")
    687            ),
    688            exp.VarMap: lambda self, e: _lower_func(var_map_sql(self, e)),
    689            exp.Xor: lambda self, e: self.func("xor", e.this, e.expression, *e.expressions),
    690        }
    691
    692        PROPERTIES_LOCATION = {
    693            **generator.Generator.PROPERTIES_LOCATION,
    694            exp.VolatileProperty: exp.Properties.Location.UNSUPPORTED,
    695            exp.PartitionedByProperty: exp.Properties.Location.POST_SCHEMA,
    696            exp.OnCluster: exp.Properties.Location.POST_NAME,
    697        }
    698
    699        JOIN_HINTS = False
    700        TABLE_HINTS = False
    701        EXPLICIT_UNION = True
    702        GROUPINGS_SEP = ""
    703        OUTER_UNION_MODIFIERS = False
    704
    705        # there's no list in docs, but it can be found in Clickhouse code
    706        # see `ClickHouse/src/Parsers/ParserCreate*.cpp`
    707        ON_CLUSTER_TARGETS = {
    708            "DATABASE",
    709            "TABLE",
    710            "VIEW",
    711            "DICTIONARY",
    712            "INDEX",
    713            "FUNCTION",
    714            "NAMED COLLECTION",
    715        }
    716
    717        def _jsonpathsubscript_sql(self, expression: exp.JSONPathSubscript) -> str:
    718            this = self.json_path_part(expression.this)
    719            return str(int(this) + 1) if is_int(this) else this
    720
    721        def likeproperty_sql(self, expression: exp.LikeProperty) -> str:
    722            return f"AS {self.sql(expression, 'this')}"
    723
    724        def _any_to_has(
    725            self,
    726            expression: exp.EQ | exp.NEQ,
    727            default: t.Callable[[t.Any], str],
    728            prefix: str = "",
    729        ) -> str:
    730            if isinstance(expression.left, exp.Any):
    731                arr = expression.left
    732                this = expression.right
    733            elif isinstance(expression.right, exp.Any):
    734                arr = expression.right
    735                this = expression.left
    736            else:
    737                return default(expression)
    738
    739            return prefix + self.func("has", arr.this.unnest(), this)
    740
    741        def eq_sql(self, expression: exp.EQ) -> str:
    742            return self._any_to_has(expression, super().eq_sql)
    743
    744        def neq_sql(self, expression: exp.NEQ) -> str:
    745            return self._any_to_has(expression, super().neq_sql, "NOT ")
    746
    747        def regexpilike_sql(self, expression: exp.RegexpILike) -> str:
    748            # Manually add a flag to make the search case-insensitive
    749            regex = self.func("CONCAT", "'(?i)'", expression.expression)
    750            return self.func("match", expression.this, regex)
    751
    752        def datatype_sql(self, expression: exp.DataType) -> str:
    753            # String is the standard ClickHouse type, every other variant is just an alias.
    754            # Additionally, any supplied length parameter will be ignored.
    755            #
    756            # https://clickhouse.com/docs/en/sql-reference/data-types/string
    757            if expression.this in self.STRING_TYPE_MAPPING:
    758                return "String"
    759
    760            return super().datatype_sql(expression)
    761
    762        def cte_sql(self, expression: exp.CTE) -> str:
    763            if expression.args.get("scalar"):
    764                this = self.sql(expression, "this")
    765                alias = self.sql(expression, "alias")
    766                return f"{this} AS {alias}"
    767
    768            return super().cte_sql(expression)
    769
    770        def after_limit_modifiers(self, expression: exp.Expression) -> t.List[str]:
    771            return super().after_limit_modifiers(expression) + [
    772                (
    773                    self.seg("SETTINGS ") + self.expressions(expression, key="settings", flat=True)
    774                    if expression.args.get("settings")
    775                    else ""
    776                ),
    777                (
    778                    self.seg("FORMAT ") + self.sql(expression, "format")
    779                    if expression.args.get("format")
    780                    else ""
    781                ),
    782            ]
    783
    784        def parameterizedagg_sql(self, expression: exp.ParameterizedAgg) -> str:
    785            params = self.expressions(expression, key="params", flat=True)
    786            return self.func(expression.name, *expression.expressions) + f"({params})"
    787
    788        def anonymousaggfunc_sql(self, expression: exp.AnonymousAggFunc) -> str:
    789            return self.func(expression.name, *expression.expressions)
    790
    791        def combinedaggfunc_sql(self, expression: exp.CombinedAggFunc) -> str:
    792            return self.anonymousaggfunc_sql(expression)
    793
    794        def combinedparameterizedagg_sql(self, expression: exp.CombinedParameterizedAgg) -> str:
    795            return self.parameterizedagg_sql(expression)
    796
    797        def placeholder_sql(self, expression: exp.Placeholder) -> str:
    798            return f"{{{expression.name}: {self.sql(expression, 'kind')}}}"
    799
    800        def oncluster_sql(self, expression: exp.OnCluster) -> str:
    801            return f"ON CLUSTER {self.sql(expression, 'this')}"
    802
    803        def createable_sql(self, expression: exp.Create, locations: t.DefaultDict) -> str:
    804            if expression.kind in self.ON_CLUSTER_TARGETS and locations.get(
    805                exp.Properties.Location.POST_NAME
    806            ):
    807                this_name = self.sql(expression.this, "this")
    808                this_properties = " ".join(
    809                    [self.sql(prop) for prop in locations[exp.Properties.Location.POST_NAME]]
    810                )
    811                this_schema = self.schema_columns_sql(expression.this)
    812                return f"{this_name}{self.sep()}{this_properties}{self.sep()}{this_schema}"
    813
    814            return super().createable_sql(expression, locations)
    815
    816        def prewhere_sql(self, expression: exp.PreWhere) -> str:
    817            this = self.indent(self.sql(expression, "this"))
    818            return f"{self.seg('PREWHERE')}{self.sep()}{this}"
    819
    820        def indexcolumnconstraint_sql(self, expression: exp.IndexColumnConstraint) -> str:
    821            this = self.sql(expression, "this")
    822            this = f" {this}" if this else ""
    823            expr = self.sql(expression, "expression")
    824            expr = f" {expr}" if expr else ""
    825            index_type = self.sql(expression, "index_type")
    826            index_type = f" TYPE {index_type}" if index_type else ""
    827            granularity = self.sql(expression, "granularity")
    828            granularity = f" GRANULARITY {granularity}" if granularity else ""
    829
    830            return f"INDEX{this}{expr}{index_type}{granularity}"

class ClickHouse(sqlglot.dialects.dialect.Dialect): View Source

     58class ClickHouse(Dialect):
     59    NORMALIZE_FUNCTIONS: bool | str = False
     60    NULL_ORDERING = "nulls_are_last"
     61    SUPPORTS_USER_DEFINED_TYPES = False
     62    SAFE_DIVISION = True
     63    LOG_BASE_FIRST: t.Optional[bool] = None
     64
     65    UNESCAPED_SEQUENCES = {
     66        "\\0": "\0",
     67    }
     68
     69    class Tokenizer(tokens.Tokenizer):
     70        COMMENTS = ["--", "#", "#!", ("/*", "*/")]
     71        IDENTIFIERS = ['"', "`"]
     72        STRING_ESCAPES = ["'", "\\"]
     73        BIT_STRINGS = [("0b", "")]
     74        HEX_STRINGS = [("0x", ""), ("0X", "")]
     75        HEREDOC_STRINGS = ["$"]
     76
     77        KEYWORDS = {
     78            **tokens.Tokenizer.KEYWORDS,
     79            "ATTACH": TokenType.COMMAND,
     80            "DATE32": TokenType.DATE32,
     81            "DATETIME64": TokenType.DATETIME64,
     82            "DICTIONARY": TokenType.DICTIONARY,
     83            "ENUM8": TokenType.ENUM8,
     84            "ENUM16": TokenType.ENUM16,
     85            "FINAL": TokenType.FINAL,
     86            "FIXEDSTRING": TokenType.FIXEDSTRING,
     87            "FLOAT32": TokenType.FLOAT,
     88            "FLOAT64": TokenType.DOUBLE,
     89            "GLOBAL": TokenType.GLOBAL,
     90            "INT256": TokenType.INT256,
     91            "LOWCARDINALITY": TokenType.LOWCARDINALITY,
     92            "MAP": TokenType.MAP,
     93            "NESTED": TokenType.NESTED,
     94            "SAMPLE": TokenType.TABLE_SAMPLE,
     95            "TUPLE": TokenType.STRUCT,
     96            "UINT128": TokenType.UINT128,
     97            "UINT16": TokenType.USMALLINT,
     98            "UINT256": TokenType.UINT256,
     99            "UINT32": TokenType.UINT,
    100            "UINT64": TokenType.UBIGINT,
    101            "UINT8": TokenType.UTINYINT,
    102            "IPV4": TokenType.IPV4,
    103            "IPV6": TokenType.IPV6,
    104            "AGGREGATEFUNCTION": TokenType.AGGREGATEFUNCTION,
    105            "SIMPLEAGGREGATEFUNCTION": TokenType.SIMPLEAGGREGATEFUNCTION,
    106            "SYSTEM": TokenType.COMMAND,
    107            "PREWHERE": TokenType.PREWHERE,
    108        }
    109
    110        SINGLE_TOKENS = {
    111            **tokens.Tokenizer.SINGLE_TOKENS,
    112            "$": TokenType.HEREDOC_STRING,
    113        }
    114
    115    class Parser(parser.Parser):
    116        # Tested in ClickHouse's playground, it seems that the following two queries do the same thing
    117        # * select x from t1 union all select x from t2 limit 1;
    118        # * select x from t1 union all (select x from t2 limit 1);
    119        MODIFIERS_ATTACHED_TO_UNION = False
    120        INTERVAL_SPANS = False
    121
    122        FUNCTIONS = {
    123            **parser.Parser.FUNCTIONS,
    124            "ANY": exp.AnyValue.from_arg_list,
    125            "ARRAYSUM": exp.ArraySum.from_arg_list,
    126            "COUNTIF": _build_count_if,
    127            "DATE_ADD": lambda args: exp.DateAdd(
    128                this=seq_get(args, 2), expression=seq_get(args, 1), unit=seq_get(args, 0)
    129            ),
    130            "DATEADD": lambda args: exp.DateAdd(
    131                this=seq_get(args, 2), expression=seq_get(args, 1), unit=seq_get(args, 0)
    132            ),
    133            "DATE_DIFF": lambda args: exp.DateDiff(
    134                this=seq_get(args, 2), expression=seq_get(args, 1), unit=seq_get(args, 0)
    135            ),
    136            "DATEDIFF": lambda args: exp.DateDiff(
    137                this=seq_get(args, 2), expression=seq_get(args, 1), unit=seq_get(args, 0)
    138            ),
    139            "DATE_FORMAT": _build_date_format,
    140            "FORMATDATETIME": _build_date_format,
    141            "JSONEXTRACTSTRING": build_json_extract_path(
    142                exp.JSONExtractScalar, zero_based_indexing=False
    143            ),
    144            "MAP": parser.build_var_map,
    145            "MATCH": exp.RegexpLike.from_arg_list,
    146            "RANDCANONICAL": exp.Rand.from_arg_list,
    147            "TUPLE": exp.Struct.from_arg_list,
    148            "UNIQ": exp.ApproxDistinct.from_arg_list,
    149            "XOR": lambda args: exp.Xor(expressions=args),
    150        }
    151
    152        AGG_FUNCTIONS = {
    153            "count",
    154            "min",
    155            "max",
    156            "sum",
    157            "avg",
    158            "any",
    159            "stddevPop",
    160            "stddevSamp",
    161            "varPop",
    162            "varSamp",
    163            "corr",
    164            "covarPop",
    165            "covarSamp",
    166            "entropy",
    167            "exponentialMovingAverage",
    168            "intervalLengthSum",
    169            "kolmogorovSmirnovTest",
    170            "mannWhitneyUTest",
    171            "median",
    172            "rankCorr",
    173            "sumKahan",
    174            "studentTTest",
    175            "welchTTest",
    176            "anyHeavy",
    177            "anyLast",
    178            "boundingRatio",
    179            "first_value",
    180            "last_value",
    181            "argMin",
    182            "argMax",
    183            "avgWeighted",
    184            "topK",
    185            "topKWeighted",
    186            "deltaSum",
    187            "deltaSumTimestamp",
    188            "groupArray",
    189            "groupArrayLast",
    190            "groupUniqArray",
    191            "groupArrayInsertAt",
    192            "groupArrayMovingAvg",
    193            "groupArrayMovingSum",
    194            "groupArraySample",
    195            "groupBitAnd",
    196            "groupBitOr",
    197            "groupBitXor",
    198            "groupBitmap",
    199            "groupBitmapAnd",
    200            "groupBitmapOr",
    201            "groupBitmapXor",
    202            "sumWithOverflow",
    203            "sumMap",
    204            "minMap",
    205            "maxMap",
    206            "skewSamp",
    207            "skewPop",
    208            "kurtSamp",
    209            "kurtPop",
    210            "uniq",
    211            "uniqExact",
    212            "uniqCombined",
    213            "uniqCombined64",
    214            "uniqHLL12",
    215            "uniqTheta",
    216            "quantile",
    217            "quantiles",
    218            "quantileExact",
    219            "quantilesExact",
    220            "quantileExactLow",
    221            "quantilesExactLow",
    222            "quantileExactHigh",
    223            "quantilesExactHigh",
    224            "quantileExactWeighted",
    225            "quantilesExactWeighted",
    226            "quantileTiming",
    227            "quantilesTiming",
    228            "quantileTimingWeighted",
    229            "quantilesTimingWeighted",
    230            "quantileDeterministic",
    231            "quantilesDeterministic",
    232            "quantileTDigest",
    233            "quantilesTDigest",
    234            "quantileTDigestWeighted",
    235            "quantilesTDigestWeighted",
    236            "quantileBFloat16",
    237            "quantilesBFloat16",
    238            "quantileBFloat16Weighted",
    239            "quantilesBFloat16Weighted",
    240            "simpleLinearRegression",
    241            "stochasticLinearRegression",
    242            "stochasticLogisticRegression",
    243            "categoricalInformationValue",
    244            "contingency",
    245            "cramersV",
    246            "cramersVBiasCorrected",
    247            "theilsU",
    248            "maxIntersections",
    249            "maxIntersectionsPosition",
    250            "meanZTest",
    251            "quantileInterpolatedWeighted",
    252            "quantilesInterpolatedWeighted",
    253            "quantileGK",
    254            "quantilesGK",
    255            "sparkBar",
    256            "sumCount",
    257            "largestTriangleThreeBuckets",
    258            "histogram",
    259            "sequenceMatch",
    260            "sequenceCount",
    261            "windowFunnel",
    262            "retention",
    263            "uniqUpTo",
    264            "sequenceNextNode",
    265            "exponentialTimeDecayedAvg",
    266        }
    267
    268        AGG_FUNCTIONS_SUFFIXES = [
    269            "If",
    270            "Array",
    271            "ArrayIf",
    272            "Map",
    273            "SimpleState",
    274            "State",
    275            "Merge",
    276            "MergeState",
    277            "ForEach",
    278            "Distinct",
    279            "OrDefault",
    280            "OrNull",
    281            "Resample",
    282            "ArgMin",
    283            "ArgMax",
    284        ]
    285
    286        FUNC_TOKENS = {
    287            *parser.Parser.FUNC_TOKENS,
    288            TokenType.SET,
    289        }
    290
    291        AGG_FUNC_MAPPING = (
    292            lambda functions, suffixes: {
    293                f"{f}{sfx}": (f, sfx) for sfx in (suffixes + [""]) for f in functions
    294            }
    295        )(AGG_FUNCTIONS, AGG_FUNCTIONS_SUFFIXES)
    296
    297        FUNCTIONS_WITH_ALIASED_ARGS = {*parser.Parser.FUNCTIONS_WITH_ALIASED_ARGS, "TUPLE"}
    298
    299        FUNCTION_PARSERS = {
    300            **parser.Parser.FUNCTION_PARSERS,
    301            "ARRAYJOIN": lambda self: self.expression(exp.Explode, this=self._parse_expression()),
    302            "QUANTILE": lambda self: self._parse_quantile(),
    303        }
    304
    305        FUNCTION_PARSERS.pop("MATCH")
    306
    307        NO_PAREN_FUNCTION_PARSERS = parser.Parser.NO_PAREN_FUNCTION_PARSERS.copy()
    308        NO_PAREN_FUNCTION_PARSERS.pop("ANY")
    309
    310        RANGE_PARSERS = {
    311            **parser.Parser.RANGE_PARSERS,
    312            TokenType.GLOBAL: lambda self, this: self._match(TokenType.IN)
    313            and self._parse_in(this, is_global=True),
    314        }
    315
    316        # The PLACEHOLDER entry is popped because 1) it doesn't affect Clickhouse (it corresponds to
    317        # the postgres-specific JSONBContains parser) and 2) it makes parsing the ternary op simpler.
    318        COLUMN_OPERATORS = parser.Parser.COLUMN_OPERATORS.copy()
    319        COLUMN_OPERATORS.pop(TokenType.PLACEHOLDER)
    320
    321        JOIN_KINDS = {
    322            *parser.Parser.JOIN_KINDS,
    323            TokenType.ANY,
    324            TokenType.ASOF,
    325            TokenType.ARRAY,
    326        }
    327
    328        TABLE_ALIAS_TOKENS = parser.Parser.TABLE_ALIAS_TOKENS - {
    329            TokenType.ANY,
    330            TokenType.ARRAY,
    331            TokenType.FINAL,
    332            TokenType.FORMAT,
    333            TokenType.SETTINGS,
    334        }
    335
    336        ALIAS_TOKENS = parser.Parser.ALIAS_TOKENS - {
    337            TokenType.FORMAT,
    338        }
    339
    340        LOG_DEFAULTS_TO_LN = True
    341
    342        QUERY_MODIFIER_PARSERS = {
    343            **parser.Parser.QUERY_MODIFIER_PARSERS,
    344            TokenType.SETTINGS: lambda self: (
    345                "settings",
    346                self._advance() or self._parse_csv(self._parse_conjunction),
    347            ),
    348            TokenType.FORMAT: lambda self: ("format", self._advance() or self._parse_id_var()),
    349        }
    350
    351        CONSTRAINT_PARSERS = {
    352            **parser.Parser.CONSTRAINT_PARSERS,
    353            "INDEX": lambda self: self._parse_index_constraint(),
    354            "CODEC": lambda self: self._parse_compress(),
    355        }
    356
    357        SCHEMA_UNNAMED_CONSTRAINTS = {
    358            *parser.Parser.SCHEMA_UNNAMED_CONSTRAINTS,
    359            "INDEX",
    360        }
    361
    362        def _parse_conjunction(self) -> t.Optional[exp.Expression]:
    363            this = super()._parse_conjunction()
    364
    365            if self._match(TokenType.PLACEHOLDER):
    366                return self.expression(
    367                    exp.If,
    368                    this=this,
    369                    true=self._parse_conjunction(),
    370                    false=self._match(TokenType.COLON) and self._parse_conjunction(),
    371                )
    372
    373            return this
    374
    375        def _parse_placeholder(self) -> t.Optional[exp.Expression]:
    376            """
    377            Parse a placeholder expression like SELECT {abc: UInt32} or FROM {table: Identifier}
    378            https://clickhouse.com/docs/en/sql-reference/syntax#defining-and-using-query-parameters
    379            """
    380            if not self._match(TokenType.L_BRACE):
    381                return None
    382
    383            this = self._parse_id_var()
    384            self._match(TokenType.COLON)
    385            kind = self._parse_types(check_func=False, allow_identifiers=False) or (
    386                self._match_text_seq("IDENTIFIER") and "Identifier"
    387            )
    388
    389            if not kind:
    390                self.raise_error("Expecting a placeholder type or 'Identifier' for tables")
    391            elif not self._match(TokenType.R_BRACE):
    392                self.raise_error("Expecting }")
    393
    394            return self.expression(exp.Placeholder, this=this, kind=kind)
    395
    396        def _parse_in(self, this: t.Optional[exp.Expression], is_global: bool = False) -> exp.In:
    397            this = super()._parse_in(this)
    398            this.set("is_global", is_global)
    399            return this
    400
    401        def _parse_table(
    402            self,
    403            schema: bool = False,
    404            joins: bool = False,
    405            alias_tokens: t.Optional[t.Collection[TokenType]] = None,
    406            parse_bracket: bool = False,
    407            is_db_reference: bool = False,
    408            parse_partition: bool = False,
    409        ) -> t.Optional[exp.Expression]:
    410            this = super()._parse_table(
    411                schema=schema,
    412                joins=joins,
    413                alias_tokens=alias_tokens,
    414                parse_bracket=parse_bracket,
    415                is_db_reference=is_db_reference,
    416            )
    417
    418            if self._match(TokenType.FINAL):
    419                this = self.expression(exp.Final, this=this)
    420
    421            return this
    422
    423        def _parse_position(self, haystack_first: bool = False) -> exp.StrPosition:
    424            return super()._parse_position(haystack_first=True)
    425
    426        # https://clickhouse.com/docs/en/sql-reference/statements/select/with/
    427        def _parse_cte(self) -> exp.CTE:
    428            # WITH <identifier> AS <subquery expression>
    429            cte: t.Optional[exp.CTE] = self._try_parse(super()._parse_cte)
    430
    431            if not cte:
    432                # WITH <expression> AS <identifier>
    433                cte = self.expression(
    434                    exp.CTE,
    435                    this=self._parse_conjunction(),
    436                    alias=self._parse_table_alias(),
    437                    scalar=True,
    438                )
    439
    440            return cte
    441
    442        def _parse_join_parts(
    443            self,
    444        ) -> t.Tuple[t.Optional[Token], t.Optional[Token], t.Optional[Token]]:
    445            is_global = self._match(TokenType.GLOBAL) and self._prev
    446            kind_pre = self._match_set(self.JOIN_KINDS, advance=False) and self._prev
    447
    448            if kind_pre:
    449                kind = self._match_set(self.JOIN_KINDS) and self._prev
    450                side = self._match_set(self.JOIN_SIDES) and self._prev
    451                return is_global, side, kind
    452
    453            return (
    454                is_global,
    455                self._match_set(self.JOIN_SIDES) and self._prev,
    456                self._match_set(self.JOIN_KINDS) and self._prev,
    457            )
    458
    459        def _parse_join(
    460            self, skip_join_token: bool = False, parse_bracket: bool = False
    461        ) -> t.Optional[exp.Join]:
    462            join = super()._parse_join(skip_join_token=skip_join_token, parse_bracket=True)
    463            if join:
    464                join.set("global", join.args.pop("method", None))
    465
    466            return join
    467
    468        def _parse_function(
    469            self,
    470            functions: t.Optional[t.Dict[str, t.Callable]] = None,
    471            anonymous: bool = False,
    472            optional_parens: bool = True,
    473            any_token: bool = False,
    474        ) -> t.Optional[exp.Expression]:
    475            expr = super()._parse_function(
    476                functions=functions,
    477                anonymous=anonymous,
    478                optional_parens=optional_parens,
    479                any_token=any_token,
    480            )
    481
    482            func = expr.this if isinstance(expr, exp.Window) else expr
    483
    484            # Aggregate functions can be split in 2 parts: <func_name><suffix>
    485            parts = (
    486                self.AGG_FUNC_MAPPING.get(func.this) if isinstance(func, exp.Anonymous) else None
    487            )
    488
    489            if parts:
    490                params = self._parse_func_params(func)
    491
    492                kwargs = {
    493                    "this": func.this,
    494                    "expressions": func.expressions,
    495                }
    496                if parts[1]:
    497                    kwargs["parts"] = parts
    498                    exp_class = exp.CombinedParameterizedAgg if params else exp.CombinedAggFunc
    499                else:
    500                    exp_class = exp.ParameterizedAgg if params else exp.AnonymousAggFunc
    501
    502                kwargs["exp_class"] = exp_class
    503                if params:
    504                    kwargs["params"] = params
    505
    506                func = self.expression(**kwargs)
    507
    508                if isinstance(expr, exp.Window):
    509                    # The window's func was parsed as Anonymous in base parser, fix its
    510                    # type to be CH style CombinedAnonymousAggFunc / AnonymousAggFunc
    511                    expr.set("this", func)
    512                elif params:
    513                    # Params have blocked super()._parse_function() from parsing the following window
    514                    # (if that exists) as they're standing between the function call and the window spec
    515                    expr = self._parse_window(func)
    516                else:
    517                    expr = func
    518
    519            return expr
    520
    521        def _parse_func_params(
    522            self, this: t.Optional[exp.Func] = None
    523        ) -> t.Optional[t.List[exp.Expression]]:
    524            if self._match_pair(TokenType.R_PAREN, TokenType.L_PAREN):
    525                return self._parse_csv(self._parse_lambda)
    526
    527            if self._match(TokenType.L_PAREN):
    528                params = self._parse_csv(self._parse_lambda)
    529                self._match_r_paren(this)
    530                return params
    531
    532            return None
    533
    534        def _parse_quantile(self) -> exp.Quantile:
    535            this = self._parse_lambda()
    536            params = self._parse_func_params()
    537            if params:
    538                return self.expression(exp.Quantile, this=params[0], quantile=this)
    539            return self.expression(exp.Quantile, this=this, quantile=exp.Literal.number(0.5))
    540
    541        def _parse_wrapped_id_vars(self, optional: bool = False) -> t.List[exp.Expression]:
    542            return super()._parse_wrapped_id_vars(optional=True)
    543
    544        def _parse_primary_key(
    545            self, wrapped_optional: bool = False, in_props: bool = False
    546        ) -> exp.PrimaryKeyColumnConstraint | exp.PrimaryKey:
    547            return super()._parse_primary_key(
    548                wrapped_optional=wrapped_optional or in_props, in_props=in_props
    549            )
    550
    551        def _parse_on_property(self) -> t.Optional[exp.Expression]:
    552            index = self._index
    553            if self._match_text_seq("CLUSTER"):
    554                this = self._parse_id_var()
    555                if this:
    556                    return self.expression(exp.OnCluster, this=this)
    557                else:
    558                    self._retreat(index)
    559            return None
    560
    561        def _parse_index_constraint(
    562            self, kind: t.Optional[str] = None
    563        ) -> exp.IndexColumnConstraint:
    564            # INDEX name1 expr TYPE type1(args) GRANULARITY value
    565            this = self._parse_id_var()
    566            expression = self._parse_conjunction()
    567
    568            index_type = self._match_text_seq("TYPE") and (
    569                self._parse_function() or self._parse_var()
    570            )
    571
    572            granularity = self._match_text_seq("GRANULARITY") and self._parse_term()
    573
    574            return self.expression(
    575                exp.IndexColumnConstraint,
    576                this=this,
    577                expression=expression,
    578                index_type=index_type,
    579                granularity=granularity,
    580            )
    581
    582    class Generator(generator.Generator):
    583        QUERY_HINTS = False
    584        STRUCT_DELIMITER = ("(", ")")
    585        NVL2_SUPPORTED = False
    586        TABLESAMPLE_REQUIRES_PARENS = False
    587        TABLESAMPLE_SIZE_IS_ROWS = False
    588        TABLESAMPLE_KEYWORDS = "SAMPLE"
    589        LAST_DAY_SUPPORTS_DATE_PART = False
    590        CAN_IMPLEMENT_ARRAY_ANY = True
    591        SUPPORTS_TO_NUMBER = False
    592
    593        STRING_TYPE_MAPPING = {
    594            exp.DataType.Type.CHAR: "String",
    595            exp.DataType.Type.LONGBLOB: "String",
    596            exp.DataType.Type.LONGTEXT: "String",
    597            exp.DataType.Type.MEDIUMBLOB: "String",
    598            exp.DataType.Type.MEDIUMTEXT: "String",
    599            exp.DataType.Type.TINYBLOB: "String",
    600            exp.DataType.Type.TINYTEXT: "String",
    601            exp.DataType.Type.TEXT: "String",
    602            exp.DataType.Type.VARBINARY: "String",
    603            exp.DataType.Type.VARCHAR: "String",
    604        }
    605
    606        SUPPORTED_JSON_PATH_PARTS = {
    607            exp.JSONPathKey,
    608            exp.JSONPathRoot,
    609            exp.JSONPathSubscript,
    610        }
    611
    612        TYPE_MAPPING = {
    613            **generator.Generator.TYPE_MAPPING,
    614            **STRING_TYPE_MAPPING,
    615            exp.DataType.Type.ARRAY: "Array",
    616            exp.DataType.Type.BIGINT: "Int64",
    617            exp.DataType.Type.DATE32: "Date32",
    618            exp.DataType.Type.DATETIME64: "DateTime64",
    619            exp.DataType.Type.DOUBLE: "Float64",
    620            exp.DataType.Type.ENUM: "Enum",
    621            exp.DataType.Type.ENUM8: "Enum8",
    622            exp.DataType.Type.ENUM16: "Enum16",
    623            exp.DataType.Type.FIXEDSTRING: "FixedString",
    624            exp.DataType.Type.FLOAT: "Float32",
    625            exp.DataType.Type.INT: "Int32",
    626            exp.DataType.Type.MEDIUMINT: "Int32",
    627            exp.DataType.Type.INT128: "Int128",
    628            exp.DataType.Type.INT256: "Int256",
    629            exp.DataType.Type.LOWCARDINALITY: "LowCardinality",
    630            exp.DataType.Type.MAP: "Map",
    631            exp.DataType.Type.NESTED: "Nested",
    632            exp.DataType.Type.NULLABLE: "Nullable",
    633            exp.DataType.Type.SMALLINT: "Int16",
    634            exp.DataType.Type.STRUCT: "Tuple",
    635            exp.DataType.Type.TINYINT: "Int8",
    636            exp.DataType.Type.UBIGINT: "UInt64",
    637            exp.DataType.Type.UINT: "UInt32",
    638            exp.DataType.Type.UINT128: "UInt128",
    639            exp.DataType.Type.UINT256: "UInt256",
    640            exp.DataType.Type.USMALLINT: "UInt16",
    641            exp.DataType.Type.UTINYINT: "UInt8",
    642            exp.DataType.Type.IPV4: "IPv4",
    643            exp.DataType.Type.IPV6: "IPv6",
    644            exp.DataType.Type.AGGREGATEFUNCTION: "AggregateFunction",
    645            exp.DataType.Type.SIMPLEAGGREGATEFUNCTION: "SimpleAggregateFunction",
    646        }
    647
    648        TRANSFORMS = {
    649            **generator.Generator.TRANSFORMS,
    650            exp.AnyValue: rename_func("any"),
    651            exp.ApproxDistinct: rename_func("uniq"),
    652            exp.ArrayFilter: lambda self, e: self.func("arrayFilter", e.expression, e.this),
    653            exp.ArraySize: rename_func("LENGTH"),
    654            exp.ArraySum: rename_func("arraySum"),
    655            exp.ArgMax: arg_max_or_min_no_count("argMax"),
    656            exp.ArgMin: arg_max_or_min_no_count("argMin"),
    657            exp.Array: inline_array_sql,
    658            exp.CastToStrType: rename_func("CAST"),
    659            exp.CountIf: rename_func("countIf"),
    660            exp.CompressColumnConstraint: lambda self,
    661            e: f"CODEC({self.expressions(e, key='this', flat=True)})",
    662            exp.ComputedColumnConstraint: lambda self,
    663            e: f"{'MATERIALIZED' if e.args.get('persisted') else 'ALIAS'} {self.sql(e, 'this')}",
    664            exp.CurrentDate: lambda self, e: self.func("CURRENT_DATE"),
    665            exp.DateAdd: date_delta_sql("DATE_ADD"),
    666            exp.DateDiff: date_delta_sql("DATE_DIFF"),
    667            exp.Explode: rename_func("arrayJoin"),
    668            exp.Final: lambda self, e: f"{self.sql(e, 'this')} FINAL",
    669            exp.IsNan: rename_func("isNaN"),
    670            exp.JSONExtract: json_extract_segments("JSONExtractString", quoted_index=False),
    671            exp.JSONExtractScalar: json_extract_segments("JSONExtractString", quoted_index=False),
    672            exp.JSONPathKey: json_path_key_only_name,
    673            exp.JSONPathRoot: lambda *_: "",
    674            exp.Map: lambda self, e: _lower_func(var_map_sql(self, e)),
    675            exp.Nullif: rename_func("nullIf"),
    676            exp.PartitionedByProperty: lambda self, e: f"PARTITION BY {self.sql(e, 'this')}",
    677            exp.Pivot: no_pivot_sql,
    678            exp.Quantile: _quantile_sql,
    679            exp.RegexpLike: lambda self, e: self.func("match", e.this, e.expression),
    680            exp.Rand: rename_func("randCanonical"),
    681            exp.Select: transforms.preprocess([transforms.eliminate_qualify]),
    682            exp.StartsWith: rename_func("startsWith"),
    683            exp.StrPosition: lambda self, e: self.func(
    684                "position", e.this, e.args.get("substr"), e.args.get("position")
    685            ),
    686            exp.TimeToStr: lambda self, e: self.func(
    687                "DATE_FORMAT", e.this, self.format_time(e), e.args.get("timezone")
    688            ),
    689            exp.VarMap: lambda self, e: _lower_func(var_map_sql(self, e)),
    690            exp.Xor: lambda self, e: self.func("xor", e.this, e.expression, *e.expressions),
    691        }
    692
    693        PROPERTIES_LOCATION = {
    694            **generator.Generator.PROPERTIES_LOCATION,
    695            exp.VolatileProperty: exp.Properties.Location.UNSUPPORTED,
    696            exp.PartitionedByProperty: exp.Properties.Location.POST_SCHEMA,
    697            exp.OnCluster: exp.Properties.Location.POST_NAME,
    698        }
    699
    700        JOIN_HINTS = False
    701        TABLE_HINTS = False
    702        EXPLICIT_UNION = True
    703        GROUPINGS_SEP = ""
    704        OUTER_UNION_MODIFIERS = False
    705
    706        # there's no list in docs, but it can be found in Clickhouse code
    707        # see `ClickHouse/src/Parsers/ParserCreate*.cpp`
    708        ON_CLUSTER_TARGETS = {
    709            "DATABASE",
    710            "TABLE",
    711            "VIEW",
    712            "DICTIONARY",
    713            "INDEX",
    714            "FUNCTION",
    715            "NAMED COLLECTION",
    716        }
    717
    718        def _jsonpathsubscript_sql(self, expression: exp.JSONPathSubscript) -> str:
    719            this = self.json_path_part(expression.this)
    720            return str(int(this) + 1) if is_int(this) else this
    721
    722        def likeproperty_sql(self, expression: exp.LikeProperty) -> str:
    723            return f"AS {self.sql(expression, 'this')}"
    724
    725        def _any_to_has(
    726            self,
    727            expression: exp.EQ | exp.NEQ,
    728            default: t.Callable[[t.Any], str],
    729            prefix: str = "",
    730        ) -> str:
    731            if isinstance(expression.left, exp.Any):
    732                arr = expression.left
    733                this = expression.right
    734            elif isinstance(expression.right, exp.Any):
    735                arr = expression.right
    736                this = expression.left
    737            else:
    738                return default(expression)
    739
    740            return prefix + self.func("has", arr.this.unnest(), this)
    741
    742        def eq_sql(self, expression: exp.EQ) -> str:
    743            return self._any_to_has(expression, super().eq_sql)
    744
    745        def neq_sql(self, expression: exp.NEQ) -> str:
    746            return self._any_to_has(expression, super().neq_sql, "NOT ")
    747
    748        def regexpilike_sql(self, expression: exp.RegexpILike) -> str:
    749            # Manually add a flag to make the search case-insensitive
    750            regex = self.func("CONCAT", "'(?i)'", expression.expression)
    751            return self.func("match", expression.this, regex)
    752
    753        def datatype_sql(self, expression: exp.DataType) -> str:
    754            # String is the standard ClickHouse type, every other variant is just an alias.
    755            # Additionally, any supplied length parameter will be ignored.
    756            #
    757            # https://clickhouse.com/docs/en/sql-reference/data-types/string
    758            if expression.this in self.STRING_TYPE_MAPPING:
    759                return "String"
    760
    761            return super().datatype_sql(expression)
    762
    763        def cte_sql(self, expression: exp.CTE) -> str:
    764            if expression.args.get("scalar"):
    765                this = self.sql(expression, "this")
    766                alias = self.sql(expression, "alias")
    767                return f"{this} AS {alias}"
    768
    769            return super().cte_sql(expression)
    770
    771        def after_limit_modifiers(self, expression: exp.Expression) -> t.List[str]:
    772            return super().after_limit_modifiers(expression) + [
    773                (
    774                    self.seg("SETTINGS ") + self.expressions(expression, key="settings", flat=True)
    775                    if expression.args.get("settings")
    776                    else ""
    777                ),
    778                (
    779                    self.seg("FORMAT ") + self.sql(expression, "format")
    780                    if expression.args.get("format")
    781                    else ""
    782                ),
    783            ]
    784
    785        def parameterizedagg_sql(self, expression: exp.ParameterizedAgg) -> str:
    786            params = self.expressions(expression, key="params", flat=True)
    787            return self.func(expression.name, *expression.expressions) + f"({params})"
    788
    789        def anonymousaggfunc_sql(self, expression: exp.AnonymousAggFunc) -> str:
    790            return self.func(expression.name, *expression.expressions)
    791
    792        def combinedaggfunc_sql(self, expression: exp.CombinedAggFunc) -> str:
    793            return self.anonymousaggfunc_sql(expression)
    794
    795        def combinedparameterizedagg_sql(self, expression: exp.CombinedParameterizedAgg) -> str:
    796            return self.parameterizedagg_sql(expression)
    797
    798        def placeholder_sql(self, expression: exp.Placeholder) -> str:
    799            return f"{{{expression.name}: {self.sql(expression, 'kind')}}}"
    800
    801        def oncluster_sql(self, expression: exp.OnCluster) -> str:
    802            return f"ON CLUSTER {self.sql(expression, 'this')}"
    803
    804        def createable_sql(self, expression: exp.Create, locations: t.DefaultDict) -> str:
    805            if expression.kind in self.ON_CLUSTER_TARGETS and locations.get(
    806                exp.Properties.Location.POST_NAME
    807            ):
    808                this_name = self.sql(expression.this, "this")
    809                this_properties = " ".join(
    810                    [self.sql(prop) for prop in locations[exp.Properties.Location.POST_NAME]]
    811                )
    812                this_schema = self.schema_columns_sql(expression.this)
    813                return f"{this_name}{self.sep()}{this_properties}{self.sep()}{this_schema}"
    814
    815            return super().createable_sql(expression, locations)
    816
    817        def prewhere_sql(self, expression: exp.PreWhere) -> str:
    818            this = self.indent(self.sql(expression, "this"))
    819            return f"{self.seg('PREWHERE')}{self.sep()}{this}"
    820
    821        def indexcolumnconstraint_sql(self, expression: exp.IndexColumnConstraint) -> str:
    822            this = self.sql(expression, "this")
    823            this = f" {this}" if this else ""
    824            expr = self.sql(expression, "expression")
    825            expr = f" {expr}" if expr else ""
    826            index_type = self.sql(expression, "index_type")
    827            index_type = f" TYPE {index_type}" if index_type else ""
    828            granularity = self.sql(expression, "granularity")
    829            granularity = f" GRANULARITY {granularity}" if granularity else ""
    830
    831            return f"INDEX{this}{expr}{index_type}{granularity}"

NORMALIZE_FUNCTIONS: bool | str = False

Determines how function names are going to be normalized.

###### Possible values:

> "upper" or True: Convert names to uppercase. "lower": Convert names to lowercase. False: Disables function name normalization.

NULL_ORDERING = 'nulls_are_last'

Default `NULL` ordering method to use if not explicitly set. Possible values: `"nulls_are_small"`, `"nulls_are_large"`, `"nulls_are_last"`

SUPPORTS_USER_DEFINED_TYPES = False

Whether user-defined data types are supported.

SAFE_DIVISION = True

Whether division by zero throws an error (`False`) or returns NULL (`True`).

LOG_BASE_FIRST: Optional[bool] = None

Whether the base comes first in the `LOG` function. Possible values: `True`, `False`, `None` (two arguments are not supported by `LOG`)

UNESCAPED_SEQUENCES = {'\\a': '\x07', '\\b': '\x08', '\\f': '\x0c', '\\n': '\n', '\\r': '\r', '\\t': '\t', '\\v': '\x0b', '\\\\': '\\', '\\0': '\x00'}

Mapping of an escaped sequence (`\n`) to its unescaped version (`` ).

tokenizer_class = <class 'ClickHouse.Tokenizer'>
parser_class = <class 'ClickHouse.Parser'>
generator_class = <class 'ClickHouse.Generator'>
TIME_TRIE: Dict = {}
FORMAT_TRIE: Dict = {}
INVERSE_TIME_MAPPING: Dict[str, str] = {}
INVERSE_TIME_TRIE: Dict = {}
ESCAPED_SEQUENCES: Dict[str, str] = {'\x07': '\\a', '\x08': '\\b', '\x0c': '\\f', '\n': '\\n', '\r': '\\r', '\t': '\\t', '\x0b': '\\v', '\\': '\\\\', '\x00': '\\0'}
QUOTE_START = "'"
QUOTE_END = "'"
IDENTIFIER_START = '"'
IDENTIFIER_END = '"'
BIT_START: Optional[str] = '0b'
BIT_END: Optional[str] = ''
HEX_START: Optional[str] = '0x'
HEX_END: Optional[str] = ''
BYTE_START: Optional[str] = None
BYTE_END: Optional[str] = None
UNICODE_START: Optional[str] = None
UNICODE_END: Optional[str] = None

##### Inherited Members

sqlglot.dialects.dialect.Dialect
  Dialect
  INDEX_OFFSET
  WEEK_OFFSET
  UNNEST_COLUMN_ONLY
  ALIAS_POST_TABLESAMPLE
  TABLESAMPLE_SIZE_IS_PERCENT
  NORMALIZATION_STRATEGY
  IDENTIFIERS_CAN_START_WITH_DIGIT
  DPIPE_IS_STRING_CONCAT
  STRICT_STRING_CONCAT
  SUPPORTS_SEMI_ANTI_JOIN
  TYPED_DIVISION
  CONCAT_COALESCE
  DATE_FORMAT
  DATEINT_FORMAT
  TIME_FORMAT
  TIME_MAPPING
  FORMAT_MAPPING
  PSEUDOCOLUMNS
  PREFER_CTE_ALIAS_COLUMN
  COPY_PARAMS_ARE_CSV
  get_or_raise
  format_time
  normalize_identifier
  case_sensitive
  can_identify
  quote_identifier
  to_json_path
  parse
  parse_into
  generate
  transpile
  tokenize
  tokenizer
  parser
  generator

class ClickHouse.Tokenizer(sqlglot.tokens.Tokenizer): View Source

     69    class Tokenizer(tokens.Tokenizer):
     70        COMMENTS = ["--", "#", "#!", ("/*", "*/")]
     71        IDENTIFIERS = ['"', "`"]
     72        STRING_ESCAPES = ["'", "\\"]
     73        BIT_STRINGS = [("0b", "")]
     74        HEX_STRINGS = [("0x", ""), ("0X", "")]
     75        HEREDOC_STRINGS = ["$"]
     76
     77        KEYWORDS = {
     78            **tokens.Tokenizer.KEYWORDS,
     79            "ATTACH": TokenType.COMMAND,
     80            "DATE32": TokenType.DATE32,
     81            "DATETIME64": TokenType.DATETIME64,
     82            "DICTIONARY": TokenType.DICTIONARY,
     83            "ENUM8": TokenType.ENUM8,
     84            "ENUM16": TokenType.ENUM16,
     85            "FINAL": TokenType.FINAL,
     86            "FIXEDSTRING": TokenType.FIXEDSTRING,
     87            "FLOAT32": TokenType.FLOAT,
     88            "FLOAT64": TokenType.DOUBLE,
     89            "GLOBAL": TokenType.GLOBAL,
     90            "INT256": TokenType.INT256,
     91            "LOWCARDINALITY": TokenType.LOWCARDINALITY,
     92            "MAP": TokenType.MAP,
     93            "NESTED": TokenType.NESTED,
     94            "SAMPLE": TokenType.TABLE_SAMPLE,
     95            "TUPLE": TokenType.STRUCT,
     96            "UINT128": TokenType.UINT128,
     97            "UINT16": TokenType.USMALLINT,
     98            "UINT256": TokenType.UINT256,
     99            "UINT32": TokenType.UINT,
    100            "UINT64": TokenType.UBIGINT,
    101            "UINT8": TokenType.UTINYINT,
    102            "IPV4": TokenType.IPV4,
    103            "IPV6": TokenType.IPV6,
    104            "AGGREGATEFUNCTION": TokenType.AGGREGATEFUNCTION,
    105            "SIMPLEAGGREGATEFUNCTION": TokenType.SIMPLEAGGREGATEFUNCTION,
    106            "SYSTEM": TokenType.COMMAND,
    107            "PREWHERE": TokenType.PREWHERE,
    108        }
    109
    110        SINGLE_TOKENS = {
    111            **tokens.Tokenizer.SINGLE_TOKENS,
    112            "$": TokenType.HEREDOC_STRING,
    113        }

COMMENTS = ['--', '#', '#!', ('/*', '*/')]
IDENTIFIERS = ['"', '`']
STRING_ESCAPES = ["'", '\\']
BIT_STRINGS = [('0b', '')]
HEX_STRINGS = [('0x', ''), ('0X', '')]
HEREDOC_STRINGS = ['$']
KEYWORDS = {'{%': <TokenType.BLOCK_START: 'BLOCK_START'>, '{%+': <TokenType.BLOCK_START: 'BLOCK_START'>, '{%-': <TokenType.BLOCK_START: 'BLOCK_START'>, '%}': <TokenType.BLOCK_END: 'BLOCK_END'>, '+%}': <TokenType.BLOCK_END: 'BLOCK_END'>, '-%}': <TokenType.BLOCK_END: 'BLOCK_END'>, '{{+': <TokenType.BLOCK_START: 'BLOCK_START'>, '{{-': <TokenType.BLOCK_START: 'BLOCK_START'>, '+}}': <TokenType.BLOCK_END: 'BLOCK_END'>, '-}}': <TokenType.BLOCK_END: 'BLOCK_END'>, '/*+': <TokenType.HINT: 'HINT'>, '==': <TokenType.EQ: 'EQ'>, '::': <TokenType.DCOLON: 'DCOLON'>, '||': <TokenType.DPIPE: 'DPIPE'>, '>=': <TokenType.GTE: 'GTE'>, '<=': <TokenType.LTE: 'LTE'>, '<>': <TokenType.NEQ: 'NEQ'>, '!=': <TokenType.NEQ: 'NEQ'>, ':=': <TokenType.COLON_EQ: 'COLON_EQ'>, '<=>': <TokenType.NULLSAFE_EQ: 'NULLSAFE_EQ'>, '->': <TokenType.ARROW: 'ARROW'>, '->>': <TokenType.DARROW: 'DARROW'>, '=>': <TokenType.FARROW: 'FARROW'>, '#>': <TokenType.HASH_ARROW: 'HASH_ARROW'>, '#>>': <TokenType.DHASH_ARROW: 'DHASH_ARROW'>, '<->': <TokenType.LR_ARROW: 'LR_ARROW'>, '&&': <TokenType.DAMP: 'DAMP'>, '??': <TokenType.DQMARK: 'DQMARK'>, 'ALL': <TokenType.ALL: 'ALL'>, 'ALWAYS': <TokenType.ALWAYS: 'ALWAYS'>, 'AND': <TokenType.AND: 'AND'>, 'ANTI': <TokenType.ANTI: 'ANTI'>, 'ANY': <TokenType.ANY: 'ANY'>, 'ASC': <TokenType.ASC: 'ASC'>, 'AS': <TokenType.ALIAS: 'ALIAS'>, 'ASOF': <TokenType.ASOF: 'ASOF'>, 'AUTOINCREMENT': <TokenType.AUTO_INCREMENT: 'AUTO_INCREMENT'>, 'AUTO_INCREMENT': <TokenType.AUTO_INCREMENT: 'AUTO_INCREMENT'>, 'BEGIN': <TokenType.BEGIN: 'BEGIN'>, 'BETWEEN': <TokenType.BETWEEN: 'BETWEEN'>, 'CACHE': <TokenType.CACHE: 'CACHE'>, 'UNCACHE': <TokenType.UNCACHE: 'UNCACHE'>, 'CASE': <TokenType.CASE: 'CASE'>, 'CHARACTER SET': <TokenType.CHARACTER_SET: 'CHARACTER_SET'>, 'CLUSTER BY': <TokenType.CLUSTER_BY: 'CLUSTER_BY'>, 'COLLATE': <TokenType.COLLATE: 'COLLATE'>, 'COLUMN': <TokenType.COLUMN: 'COLUMN'>, 'COMMIT': <TokenType.COMMIT: 'COMMIT'>, 'CONNECT BY': <TokenType.CONNECT_BY: 'CONNECT_BY'>, 'CONSTRAINT': <TokenType.CONSTRAINT: 'CONSTRAINT'>, 'COPY': <TokenType.COPY: 'COPY'>, 'CREATE': <TokenType.CREATE: 'CREATE'>, 'CROSS': <TokenType.CROSS: 'CROSS'>, 'CUBE': <TokenType.CUBE: 'CUBE'>, 'CURRENT_DATE': <TokenType.CURRENT_DATE: 'CURRENT_DATE'>, 'CURRENT_TIME': <TokenType.CURRENT_TIME: 'CURRENT_TIME'>, 'CURRENT_TIMESTAMP': <TokenType.CURRENT_TIMESTAMP: 'CURRENT_TIMESTAMP'>, 'CURRENT_USER': <TokenType.CURRENT_USER: 'CURRENT_USER'>, 'DATABASE': <TokenType.DATABASE: 'DATABASE'>, 'DEFAULT': <TokenType.DEFAULT: 'DEFAULT'>, 'DELETE': <TokenType.DELETE: 'DELETE'>, 'DESC': <TokenType.DESC: 'DESC'>, 'DESCRIBE': <TokenType.DESCRIBE: 'DESCRIBE'>, 'DISTINCT': <TokenType.DISTINCT: 'DISTINCT'>, 'DISTRIBUTE BY': <TokenType.DISTRIBUTE_BY: 'DISTRIBUTE_BY'>, 'DIV': <TokenType.DIV: 'DIV'>, 'DROP': <TokenType.DROP: 'DROP'>, 'ELSE': <TokenType.ELSE: 'ELSE'>, 'END': <TokenType.END: 'END'>, 'ENUM': <TokenType.ENUM: 'ENUM'>, 'ESCAPE': <TokenType.ESCAPE: 'ESCAPE'>, 'EXCEPT': <TokenType.EXCEPT: 'EXCEPT'>, 'EXECUTE': <TokenType.EXECUTE: 'EXECUTE'>, 'EXISTS': <TokenType.EXISTS: 'EXISTS'>, 'FALSE': <TokenType.FALSE: 'FALSE'>, 'FETCH': <TokenType.FETCH: 'FETCH'>, 'FILTER': <TokenType.FILTER: 'FILTER'>, 'FIRST': <TokenType.FIRST: 'FIRST'>, 'FULL': <TokenType.FULL: 'FULL'>, 'FUNCTION': <TokenType.FUNCTION: 'FUNCTION'>, 'FOR': <TokenType.FOR: 'FOR'>, 'FOREIGN KEY': <TokenType.FOREIGN_KEY: 'FOREIGN_KEY'>, 'FORMAT': <TokenType.FORMAT: 'FORMAT'>, 'FROM': <TokenType.FROM: 'FROM'>, 'GEOGRAPHY': <TokenType.GEOGRAPHY: 'GEOGRAPHY'>, 'GEOMETRY': <TokenType.GEOMETRY: 'GEOMETRY'>, 'GLOB': <TokenType.GLOB: 'GLOB'>, 'GROUP BY': <TokenType.GROUP_BY: 'GROUP_BY'>, 'GROUPING SETS': <TokenType.GROUPING_SETS: 'GROUPING_SETS'>, 'HAVING': <TokenType.HAVING: 'HAVING'>, 'ILIKE': <TokenType.ILIKE: 'ILIKE'>, 'IN': <TokenType.IN: 'IN'>, 'INDEX': <TokenType.INDEX: 'INDEX'>, 'INET': <TokenType.INET: 'INET'>, 'INNER': <TokenType.INNER: 'INNER'>, 'INSERT': <TokenType.INSERT: 'INSERT'>, 'INTERVAL': <TokenType.INTERVAL: 'INTERVAL'>, 'INTERSECT': <TokenType.INTERSECT: 'INTERSECT'>, 'INTO': <TokenType.INTO: 'INTO'>, 'IS': <TokenType.IS: 'IS'>, 'ISNULL': <TokenType.ISNULL: 'ISNULL'>, 'JOIN': <TokenType.JOIN: 'JOIN'>, 'KEEP': <TokenType.KEEP: 'KEEP'>, 'KILL': <TokenType.KILL: 'KILL'>, 'LATERAL': <TokenType.LATERAL: 'LATERAL'>, 'LEFT': <TokenType.LEFT: 'LEFT'>, 'LIKE': <TokenType.LIKE: 'LIKE'>, 'LIMIT': <TokenType.LIMIT: 'LIMIT'>, 'LOAD': <TokenType.LOAD: 'LOAD'>, 'LOCK': <TokenType.LOCK: 'LOCK'>, 'MERGE': <TokenType.MERGE: 'MERGE'>, 'NATURAL': <TokenType.NATURAL: 'NATURAL'>, 'NEXT': <TokenType.NEXT: 'NEXT'>, 'NOT': <TokenType.NOT: 'NOT'>, 'NOTNULL': <TokenType.NOTNULL: 'NOTNULL'>, 'NULL': <TokenType.NULL: 'NULL'>, 'OBJECT': <TokenType.OBJECT: 'OBJECT'>, 'OFFSET': <TokenType.OFFSET: 'OFFSET'>, 'ON': <TokenType.ON: 'ON'>, 'OR': <TokenType.OR: 'OR'>, 'XOR': <TokenType.XOR: 'XOR'>, 'ORDER BY': <TokenType.ORDER_BY: 'ORDER_BY'>, 'ORDINALITY': <TokenType.ORDINALITY: 'ORDINALITY'>, 'OUTER': <TokenType.OUTER: 'OUTER'>, 'OVER': <TokenType.OVER: 'OVER'>, 'OVERLAPS': <TokenType.OVERLAPS: 'OVERLAPS'>, 'OVERWRITE': <TokenType.OVERWRITE: 'OVERWRITE'>, 'PARTITION': <TokenType.PARTITION: 'PARTITION'>, 'PARTITION BY': <TokenType.PARTITION_BY: 'PARTITION_BY'>, 'PARTITIONED BY': <TokenType.PARTITION_BY: 'PARTITION_BY'>, 'PARTITIONED_BY': <TokenType.PARTITION_BY: 'PARTITION_BY'>, 'PERCENT': <TokenType.PERCENT: 'PERCENT'>, 'PIVOT': <TokenType.PIVOT: 'PIVOT'>, 'PRAGMA': <TokenType.PRAGMA: 'PRAGMA'>, 'PRIMARY KEY': <TokenType.PRIMARY_KEY: 'PRIMARY_KEY'>, 'PROCEDURE': <TokenType.PROCEDURE: 'PROCEDURE'>, 'QUALIFY': <TokenType.QUALIFY: 'QUALIFY'>, 'RANGE': <TokenType.RANGE: 'RANGE'>, 'RECURSIVE': <TokenType.RECURSIVE: 'RECURSIVE'>, 'REGEXP': <TokenType.RLIKE: 'RLIKE'>, 'REPLACE': <TokenType.REPLACE: 'REPLACE'>, 'RETURNING': <TokenType.RETURNING: 'RETURNING'>, 'REFERENCES': <TokenType.REFERENCES: 'REFERENCES'>, 'RIGHT': <TokenType.RIGHT: 'RIGHT'>, 'RLIKE': <TokenType.RLIKE: 'RLIKE'>, 'ROLLBACK': <TokenType.ROLLBACK: 'ROLLBACK'>, 'ROLLUP': <TokenType.ROLLUP: 'ROLLUP'>, 'ROW': <TokenType.ROW: 'ROW'>, 'ROWS': <TokenType.ROWS: 'ROWS'>, 'SCHEMA': <TokenType.SCHEMA: 'SCHEMA'>, 'SELECT': <TokenType.SELECT: 'SELECT'>, 'SEMI': <TokenType.SEMI: 'SEMI'>, 'SET': <TokenType.SET: 'SET'>, 'SETTINGS': <TokenType.SETTINGS: 'SETTINGS'>, 'SHOW': <TokenType.SHOW: 'SHOW'>, 'SIMILAR TO': <TokenType.SIMILAR_TO: 'SIMILAR_TO'>, 'SOME': <TokenType.SOME: 'SOME'>, 'SORT BY': <TokenType.SORT_BY: 'SORT_BY'>, 'START WITH': <TokenType.START_WITH: 'START_WITH'>, 'TABLE': <TokenType.TABLE: 'TABLE'>, 'TABLESAMPLE': <TokenType.TABLE_SAMPLE: 'TABLE_SAMPLE'>, 'TEMP': <TokenType.TEMPORARY: 'TEMPORARY'>, 'TEMPORARY': <TokenType.TEMPORARY: 'TEMPORARY'>, 'THEN': <TokenType.THEN: 'THEN'>, 'TRUE': <TokenType.TRUE: 'TRUE'>, 'TRUNCATE': <TokenType.TRUNCATE: 'TRUNCATE'>, 'UNION': <TokenType.UNION: 'UNION'>, 'UNKNOWN': <TokenType.UNKNOWN: 'UNKNOWN'>, 'UNNEST': <TokenType.UNNEST: 'UNNEST'>, 'UNPIVOT': <TokenType.UNPIVOT: 'UNPIVOT'>, 'UPDATE': <TokenType.UPDATE: 'UPDATE'>, 'USE': <TokenType.USE: 'USE'>, 'USING': <TokenType.USING: 'USING'>, 'UUID': <TokenType.UUID: 'UUID'>, 'VALUES': <TokenType.VALUES: 'VALUES'>, 'VIEW': <TokenType.VIEW: 'VIEW'>, 'VOLATILE': <TokenType.VOLATILE: 'VOLATILE'>, 'WHEN': <TokenType.WHEN: 'WHEN'>, 'WHERE': <TokenType.WHERE: 'WHERE'>, 'WINDOW': <TokenType.WINDOW: 'WINDOW'>, 'WITH': <TokenType.WITH: 'WITH'>, 'APPLY': <TokenType.APPLY: 'APPLY'>, 'ARRAY': <TokenType.ARRAY: 'ARRAY'>, 'BIT': <TokenType.BIT: 'BIT'>, 'BOOL': <TokenType.BOOLEAN: 'BOOLEAN'>, 'BOOLEAN': <TokenType.BOOLEAN: 'BOOLEAN'>, 'BYTE': <TokenType.TINYINT: 'TINYINT'>, 'MEDIUMINT': <TokenType.MEDIUMINT: 'MEDIUMINT'>, 'INT1': <TokenType.TINYINT: 'TINYINT'>, 'TINYINT': <TokenType.TINYINT: 'TINYINT'>, 'INT16': <TokenType.SMALLINT: 'SMALLINT'>, 'SHORT': <TokenType.SMALLINT: 'SMALLINT'>, 'SMALLINT': <TokenType.SMALLINT: 'SMALLINT'>, 'INT128': <TokenType.INT128: 'INT128'>, 'HUGEINT': <TokenType.INT128: 'INT128'>, 'INT2': <TokenType.SMALLINT: 'SMALLINT'>, 'INTEGER': <TokenType.INT: 'INT'>, 'INT': <TokenType.INT: 'INT'>, 'INT4': <TokenType.INT: 'INT'>, 'INT32': <TokenType.INT: 'INT'>, 'INT64': <TokenType.BIGINT: 'BIGINT'>, 'LONG': <TokenType.BIGINT: 'BIGINT'>, 'BIGINT': <TokenType.BIGINT: 'BIGINT'>, 'INT8': <TokenType.TINYINT: 'TINYINT'>, 'UINT': <TokenType.UINT: 'UINT'>, 'DEC': <TokenType.DECIMAL: 'DECIMAL'>, 'DECIMAL': <TokenType.DECIMAL: 'DECIMAL'>, 'BIGDECIMAL': <TokenType.BIGDECIMAL: 'BIGDECIMAL'>, 'BIGNUMERIC': <TokenType.BIGDECIMAL: 'BIGDECIMAL'>, 'MAP': <TokenType.MAP: 'MAP'>, 'NULLABLE': <TokenType.NULLABLE: 'NULLABLE'>, 'NUMBER': <TokenType.DECIMAL: 'DECIMAL'>, 'NUMERIC': <TokenType.DECIMAL: 'DECIMAL'>, 'FIXED': <TokenType.DECIMAL: 'DECIMAL'>, 'REAL': <TokenType.FLOAT: 'FLOAT'>, 'FLOAT': <TokenType.FLOAT: 'FLOAT'>, 'FLOAT4': <TokenType.FLOAT: 'FLOAT'>, 'FLOAT8': <TokenType.DOUBLE: 'DOUBLE'>, 'DOUBLE': <TokenType.DOUBLE: 'DOUBLE'>, 'DOUBLE PRECISION': <TokenType.DOUBLE: 'DOUBLE'>, 'JSON': <TokenType.JSON: 'JSON'>, 'CHAR': <TokenType.CHAR: 'CHAR'>, 'CHARACTER': <TokenType.CHAR: 'CHAR'>, 'NCHAR': <TokenType.NCHAR: 'NCHAR'>, 'VARCHAR': <TokenType.VARCHAR: 'VARCHAR'>, 'VARCHAR2': <TokenType.VARCHAR: 'VARCHAR'>, 'NVARCHAR': <TokenType.NVARCHAR: 'NVARCHAR'>, 'NVARCHAR2': <TokenType.NVARCHAR: 'NVARCHAR'>, 'BPCHAR': <TokenType.BPCHAR: 'BPCHAR'>, 'STR': <TokenType.TEXT: 'TEXT'>, 'STRING': <TokenType.TEXT: 'TEXT'>, 'TEXT': <TokenType.TEXT: 'TEXT'>, 'LONGTEXT': <TokenType.LONGTEXT: 'LONGTEXT'>, 'MEDIUMTEXT': <TokenType.MEDIUMTEXT: 'MEDIUMTEXT'>, 'TINYTEXT': <TokenType.TINYTEXT: 'TINYTEXT'>, 'CLOB': <TokenType.TEXT: 'TEXT'>, 'LONGVARCHAR': <TokenType.TEXT: 'TEXT'>, 'BINARY': <TokenType.BINARY: 'BINARY'>, 'BLOB': <TokenType.VARBINARY: 'VARBINARY'>, 'LONGBLOB': <TokenType.LONGBLOB: 'LONGBLOB'>, 'MEDIUMBLOB': <TokenType.MEDIUMBLOB: 'MEDIUMBLOB'>, 'TINYBLOB': <TokenType.TINYBLOB: 'TINYBLOB'>, 'BYTEA': <TokenType.VARBINARY: 'VARBINARY'>, 'VARBINARY': <TokenType.VARBINARY: 'VARBINARY'>, 'TIME': <TokenType.TIME: 'TIME'>, 'TIMETZ': <TokenType.TIMETZ: 'TIMETZ'>, 'TIMESTAMP': <TokenType.TIMESTAMP: 'TIMESTAMP'>, 'TIMESTAMPTZ': <TokenType.TIMESTAMPTZ: 'TIMESTAMPTZ'>, 'TIMESTAMPLTZ': <TokenType.TIMESTAMPLTZ: 'TIMESTAMPLTZ'>, 'TIMESTAMP_LTZ': <TokenType.TIMESTAMPLTZ: 'TIMESTAMPLTZ'>, 'TIMESTAMPNTZ': <TokenType.TIMESTAMPNTZ: 'TIMESTAMPNTZ'>, 'TIMESTAMP_NTZ': <TokenType.TIMESTAMPNTZ: 'TIMESTAMPNTZ'>, 'DATE': <TokenType.DATE: 'DATE'>, 'DATETIME': <TokenType.DATETIME: 'DATETIME'>, 'INT4RANGE': <TokenType.INT4RANGE: 'INT4RANGE'>, 'INT4MULTIRANGE': <TokenType.INT4MULTIRANGE: 'INT4MULTIRANGE'>, 'INT8RANGE': <TokenType.INT8RANGE: 'INT8RANGE'>, 'INT8MULTIRANGE': <TokenType.INT8MULTIRANGE: 'INT8MULTIRANGE'>, 'NUMRANGE': <TokenType.NUMRANGE: 'NUMRANGE'>, 'NUMMULTIRANGE': <TokenType.NUMMULTIRANGE: 'NUMMULTIRANGE'>, 'TSRANGE': <TokenType.TSRANGE: 'TSRANGE'>, 'TSMULTIRANGE': <TokenType.TSMULTIRANGE: 'TSMULTIRANGE'>, 'TSTZRANGE': <TokenType.TSTZRANGE: 'TSTZRANGE'>, 'TSTZMULTIRANGE': <TokenType.TSTZMULTIRANGE: 'TSTZMULTIRANGE'>, 'DATERANGE': <TokenType.DATERANGE: 'DATERANGE'>, 'DATEMULTIRANGE': <TokenType.DATEMULTIRANGE: 'DATEMULTIRANGE'>, 'UNIQUE': <TokenType.UNIQUE: 'UNIQUE'>, 'STRUCT': <TokenType.STRUCT: 'STRUCT'>, 'SEQUENCE': <TokenType.SEQUENCE: 'SEQUENCE'>, 'VARIANT': <TokenType.VARIANT: 'VARIANT'>, 'ALTER': <TokenType.ALTER: 'ALTER'>, 'ANALYZE': <TokenType.COMMAND: 'COMMAND'>, 'CALL': <TokenType.COMMAND: 'COMMAND'>, 'COMMENT': <TokenType.COMMENT: 'COMMENT'>, 'EXPLAIN': <TokenType.COMMAND: 'COMMAND'>, 'GRANT': <TokenType.COMMAND: 'COMMAND'>, 'OPTIMIZE': <TokenType.COMMAND: 'COMMAND'>, 'PREPARE': <TokenType.COMMAND: 'COMMAND'>, 'VACUUM': <TokenType.COMMAND: 'COMMAND'>, 'USER-DEFINED': <TokenType.USERDEFINED: 'USERDEFINED'>, 'FOR VERSION': <TokenType.VERSION_SNAPSHOT: 'VERSION_SNAPSHOT'>, 'FOR TIMESTAMP': <TokenType.TIMESTAMP_SNAPSHOT: 'TIMESTAMP_SNAPSHOT'>, 'ATTACH': <TokenType.COMMAND: 'COMMAND'>, 'DATE32': <TokenType.DATE32: 'DATE32'>, 'DATETIME64': <TokenType.DATETIME64: 'DATETIME64'>, 'DICTIONARY': <TokenType.DICTIONARY: 'DICTIONARY'>, 'ENUM8': <TokenType.ENUM8: 'ENUM8'>, 'ENUM16': <TokenType.ENUM16: 'ENUM16'>, 'FINAL': <TokenType.FINAL: 'FINAL'>, 'FIXEDSTRING': <TokenType.FIXEDSTRING: 'FIXEDSTRING'>, 'FLOAT32': <TokenType.FLOAT: 'FLOAT'>, 'FLOAT64': <TokenType.DOUBLE: 'DOUBLE'>, 'GLOBAL': <TokenType.GLOBAL: 'GLOBAL'>, 'INT256': <TokenType.INT256: 'INT256'>, 'LOWCARDINALITY': <TokenType.LOWCARDINALITY: 'LOWCARDINALITY'>, 'NESTED': <TokenType.NESTED: 'NESTED'>, 'SAMPLE': <TokenType.TABLE_SAMPLE: 'TABLE_SAMPLE'>, 'TUPLE': <TokenType.STRUCT: 'STRUCT'>, 'UINT128': <TokenType.UINT128: 'UINT128'>, 'UINT16': <TokenType.USMALLINT: 'USMALLINT'>, 'UINT256': <TokenType.UINT256: 'UINT256'>, 'UINT32': <TokenType.UINT: 'UINT'>, 'UINT64': <TokenType.UBIGINT: 'UBIGINT'>, 'UINT8': <TokenType.UTINYINT: 'UTINYINT'>, 'IPV4': <TokenType.IPV4: 'IPV4'>, 'IPV6': <TokenType.IPV6: 'IPV6'>, 'AGGREGATEFUNCTION': <TokenType.AGGREGATEFUNCTION: 'AGGREGATEFUNCTION'>, 'SIMPLEAGGREGATEFUNCTION': <TokenType.SIMPLEAGGREGATEFUNCTION: 'SIMPLEAGGREGATEFUNCTION'>, 'SYSTEM': <TokenType.COMMAND: 'COMMAND'>, 'PREWHERE': <TokenType.PREWHERE: 'PREWHERE'>}
SINGLE_TOKENS = {'(': <TokenType.L_PAREN: 'L_PAREN'>, ')': <TokenType.R_PAREN: 'R_PAREN'>, '[': <TokenType.L_BRACKET: 'L_BRACKET'>, ']': <TokenType.R_BRACKET: 'R_BRACKET'>, '{': <TokenType.L_BRACE: 'L_BRACE'>, '}': <TokenType.R_BRACE: 'R_BRACE'>, '&': <TokenType.AMP: 'AMP'>, '^': <TokenType.CARET: 'CARET'>, ':': <TokenType.COLON: 'COLON'>, ',': <TokenType.COMMA: 'COMMA'>, '.': <TokenType.DOT: 'DOT'>, '-': <TokenType.DASH: 'DASH'>, '=': <TokenType.EQ: 'EQ'>, '>': <TokenType.GT: 'GT'>, '<': <TokenType.LT: 'LT'>, '%': <TokenType.MOD: 'MOD'>, '!': <TokenType.NOT: 'NOT'>, '|': <TokenType.PIPE: 'PIPE'>, '+': <TokenType.PLUS: 'PLUS'>, ';': <TokenType.SEMICOLON: 'SEMICOLON'>, '/': <TokenType.SLASH: 'SLASH'>, '\\': <TokenType.BACKSLASH: 'BACKSLASH'>, '*': <TokenType.STAR: 'STAR'>, '~': <TokenType.TILDA: 'TILDA'>, '?': <TokenType.PLACEHOLDER: 'PLACEHOLDER'>, '@': <TokenType.PARAMETER: 'PARAMETER'>, '#': <TokenType.HASH: 'HASH'>, "'": <TokenType.UNKNOWN: 'UNKNOWN'>, '`': <TokenType.UNKNOWN: 'UNKNOWN'>, '"': <TokenType.UNKNOWN: 'UNKNOWN'>, '$': <TokenType.HEREDOC_STRING: 'HEREDOC_STRING'>}

##### Inherited Members

sqlglot.tokens.Tokenizer
  Tokenizer
  BYTE_STRINGS
  RAW_STRINGS
  UNICODE_STRINGS
  IDENTIFIER_ESCAPES
  QUOTES
  VAR_SINGLE_TOKENS
  HEREDOC_TAG_IS_IDENTIFIER
  HEREDOC_STRING_ALTERNATIVE
  WHITE_SPACE
  COMMANDS
  COMMAND_PREFIX_TOKENS
  NUMERIC_LITERALS
  dialect
  reset
  tokenize
  tokenize_rs
  size
  sql
  tokens

class ClickHouse.Parser(sqlglot.parser.Parser): View Source

    115    class Parser(parser.Parser):
    116        # Tested in ClickHouse's playground, it seems that the following two queries do the same thing
    117        # * select x from t1 union all select x from t2 limit 1;
    118        # * select x from t1 union all (select x from t2 limit 1);
    119        MODIFIERS_ATTACHED_TO_UNION = False
    120        INTERVAL_SPANS = False
    121
    122        FUNCTIONS = {
    123            **parser.Parser.FUNCTIONS,
    124            "ANY": exp.AnyValue.from_arg_list,
    125            "ARRAYSUM": exp.ArraySum.from_arg_list,
    126            "COUNTIF": _build_count_if,
    127            "DATE_ADD": lambda args: exp.DateAdd(
    128                this=seq_get(args, 2), expression=seq_get(args, 1), unit=seq_get(args, 0)
    129            ),
    130            "DATEADD": lambda args: exp.DateAdd(
    131                this=seq_get(args, 2), expression=seq_get(args, 1), unit=seq_get(args, 0)
    132            ),
    133            "DATE_DIFF": lambda args: exp.DateDiff(
    134                this=seq_get(args, 2), expression=seq_get(args, 1), unit=seq_get(args, 0)
    135            ),
    136            "DATEDIFF": lambda args: exp.DateDiff(
    137                this=seq_get(args, 2), expression=seq_get(args, 1), unit=seq_get(args, 0)
    138            ),
    139            "DATE_FORMAT": _build_date_format,
    140            "FORMATDATETIME": _build_date_format,
    141            "JSONEXTRACTSTRING": build_json_extract_path(
    142                exp.JSONExtractScalar, zero_based_indexing=False
    143            ),
    144            "MAP": parser.build_var_map,
    145            "MATCH": exp.RegexpLike.from_arg_list,
    146            "RANDCANONICAL": exp.Rand.from_arg_list,
    147            "TUPLE": exp.Struct.from_arg_list,
    148            "UNIQ": exp.ApproxDistinct.from_arg_list,
    149            "XOR": lambda args: exp.Xor(expressions=args),
    150        }
    151
    152        AGG_FUNCTIONS = {
    153            "count",
    154            "min",
    155            "max",
    156            "sum",
    157            "avg",
    158            "any",
    159            "stddevPop",
    160            "stddevSamp",
    161            "varPop",
    162            "varSamp",
    163            "corr",
    164            "covarPop",
    165            "covarSamp",
    166            "entropy",
    167            "exponentialMovingAverage",
    168            "intervalLengthSum",
    169            "kolmogorovSmirnovTest",
    170            "mannWhitneyUTest",
    171            "median",
    172            "rankCorr",
    173            "sumKahan",
    174            "studentTTest",
    175            "welchTTest",
    176            "anyHeavy",
    177            "anyLast",
    178            "boundingRatio",
    179            "first_value",
    180            "last_value",
    181            "argMin",
    182            "argMax",
    183            "avgWeighted",
    184            "topK",
    185            "topKWeighted",
    186            "deltaSum",
    187            "deltaSumTimestamp",
    188            "groupArray",
    189            "groupArrayLast",
    190            "groupUniqArray",
    191            "groupArrayInsertAt",
    192            "groupArrayMovingAvg",
    193            "groupArrayMovingSum",
    194            "groupArraySample",
    195            "groupBitAnd",
    196            "groupBitOr",
    197            "groupBitXor",
    198            "groupBitmap",
    199            "groupBitmapAnd",
    200            "groupBitmapOr",
    201            "groupBitmapXor",
    202            "sumWithOverflow",
    203            "sumMap",
    204            "minMap",
    205            "maxMap",
    206            "skewSamp",
    207            "skewPop",
    208            "kurtSamp",
    209            "kurtPop",
    210            "uniq",
    211            "uniqExact",
    212            "uniqCombined",
    213            "uniqCombined64",
    214            "uniqHLL12",
    215            "uniqTheta",
    216            "quantile",
    217            "quantiles",
    218            "quantileExact",
    219            "quantilesExact",
    220            "quantileExactLow",
    221            "quantilesExactLow",
    222            "quantileExactHigh",
    223            "quantilesExactHigh",
    224            "quantileExactWeighted",
    225            "quantilesExactWeighted",
    226            "quantileTiming",
    227            "quantilesTiming",
    228            "quantileTimingWeighted",
    229            "quantilesTimingWeighted",
    230            "quantileDeterministic",
    231            "quantilesDeterministic",
    232            "quantileTDigest",
    233            "quantilesTDigest",
    234            "quantileTDigestWeighted",
    235            "quantilesTDigestWeighted",
    236            "quantileBFloat16",
    237            "quantilesBFloat16",
    238            "quantileBFloat16Weighted",
    239            "quantilesBFloat16Weighted",
    240            "simpleLinearRegression",
    241            "stochasticLinearRegression",
    242            "stochasticLogisticRegression",
    243            "categoricalInformationValue",
    244            "contingency",
    245            "cramersV",
    246            "cramersVBiasCorrected",
    247            "theilsU",
    248            "maxIntersections",
    249            "maxIntersectionsPosition",
    250            "meanZTest",
    251            "quantileInterpolatedWeighted",
    252            "quantilesInterpolatedWeighted",
    253            "quantileGK",
    254            "quantilesGK",
    255            "sparkBar",
    256            "sumCount",
    257            "largestTriangleThreeBuckets",
    258            "histogram",
    259            "sequenceMatch",
    260            "sequenceCount",
    261            "windowFunnel",
    262            "retention",
    263            "uniqUpTo",
    264            "sequenceNextNode",
    265            "exponentialTimeDecayedAvg",
    266        }
    267
    268        AGG_FUNCTIONS_SUFFIXES = [
    269            "If",
    270            "Array",
    271            "ArrayIf",
    272            "Map",
    273            "SimpleState",
    274            "State",
    275            "Merge",
    276            "MergeState",
    277            "ForEach",
    278            "Distinct",
    279            "OrDefault",
    280            "OrNull",
    281            "Resample",
    282            "ArgMin",
    283            "ArgMax",
    284        ]
    285
    286        FUNC_TOKENS = {
    287            *parser.Parser.FUNC_TOKENS,
    288            TokenType.SET,
    289        }
    290
    291        AGG_FUNC_MAPPING = (
    292            lambda functions, suffixes: {
    293                f"{f}{sfx}": (f, sfx) for sfx in (suffixes + [""]) for f in functions
    294            }
    295        )(AGG_FUNCTIONS, AGG_FUNCTIONS_SUFFIXES)
    296
    297        FUNCTIONS_WITH_ALIASED_ARGS = {*parser.Parser.FUNCTIONS_WITH_ALIASED_ARGS, "TUPLE"}
    298
    299        FUNCTION_PARSERS = {
    300            **parser.Parser.FUNCTION_PARSERS,
    301            "ARRAYJOIN": lambda self: self.expression(exp.Explode, this=self._parse_expression()),
    302            "QUANTILE": lambda self: self._parse_quantile(),
    303        }
    304
    305        FUNCTION_PARSERS.pop("MATCH")
    306
    307        NO_PAREN_FUNCTION_PARSERS = parser.Parser.NO_PAREN_FUNCTION_PARSERS.copy()
    308        NO_PAREN_FUNCTION_PARSERS.pop("ANY")
    309
    310        RANGE_PARSERS = {
    311            **parser.Parser.RANGE_PARSERS,
    312            TokenType.GLOBAL: lambda self, this: self._match(TokenType.IN)
    313            and self._parse_in(this, is_global=True),
    314        }
    315
    316        # The PLACEHOLDER entry is popped because 1) it doesn't affect Clickhouse (it corresponds to
    317        # the postgres-specific JSONBContains parser) and 2) it makes parsing the ternary op simpler.
    318        COLUMN_OPERATORS = parser.Parser.COLUMN_OPERATORS.copy()
    319        COLUMN_OPERATORS.pop(TokenType.PLACEHOLDER)
    320
    321        JOIN_KINDS = {
    322            *parser.Parser.JOIN_KINDS,
    323            TokenType.ANY,
    324            TokenType.ASOF,
    325            TokenType.ARRAY,
    326        }
    327
    328        TABLE_ALIAS_TOKENS = parser.Parser.TABLE_ALIAS_TOKENS - {
    329            TokenType.ANY,
    330            TokenType.ARRAY,
    331            TokenType.FINAL,
    332            TokenType.FORMAT,
    333            TokenType.SETTINGS,
    334        }
    335
    336        ALIAS_TOKENS = parser.Parser.ALIAS_TOKENS - {
    337            TokenType.FORMAT,
    338        }
    339
    340        LOG_DEFAULTS_TO_LN = True
    341
    342        QUERY_MODIFIER_PARSERS = {
    343            **parser.Parser.QUERY_MODIFIER_PARSERS,
    344            TokenType.SETTINGS: lambda self: (
    345                "settings",
    346                self._advance() or self._parse_csv(self._parse_conjunction),
    347            ),
    348            TokenType.FORMAT: lambda self: ("format", self._advance() or self._parse_id_var()),
    349        }
    350
    351        CONSTRAINT_PARSERS = {
    352            **parser.Parser.CONSTRAINT_PARSERS,
    353            "INDEX": lambda self: self._parse_index_constraint(),
    354            "CODEC": lambda self: self._parse_compress(),
    355        }
    356
    357        SCHEMA_UNNAMED_CONSTRAINTS = {
    358            *parser.Parser.SCHEMA_UNNAMED_CONSTRAINTS,
    359            "INDEX",
    360        }
    361
    362        def _parse_conjunction(self) -> t.Optional[exp.Expression]:
    363            this = super()._parse_conjunction()
    364
    365            if self._match(TokenType.PLACEHOLDER):
    366                return self.expression(
    367                    exp.If,
    368                    this=this,
    369                    true=self._parse_conjunction(),
    370                    false=self._match(TokenType.COLON) and self._parse_conjunction(),
    371                )
    372
    373            return this
    374
    375        def _parse_placeholder(self) -> t.Optional[exp.Expression]:
    376            """
    377            Parse a placeholder expression like SELECT {abc: UInt32} or FROM {table: Identifier}
    378            https://clickhouse.com/docs/en/sql-reference/syntax#defining-and-using-query-parameters
    379            """
    380            if not self._match(TokenType.L_BRACE):
    381                return None
    382
    383            this = self._parse_id_var()
    384            self._match(TokenType.COLON)
    385            kind = self._parse_types(check_func=False, allow_identifiers=False) or (
    386                self._match_text_seq("IDENTIFIER") and "Identifier"
    387            )
    388
    389            if not kind:
    390                self.raise_error("Expecting a placeholder type or 'Identifier' for tables")
    391            elif not self._match(TokenType.R_BRACE):
    392                self.raise_error("Expecting }")
    393
    394            return self.expression(exp.Placeholder, this=this, kind=kind)
    395
    396        def _parse_in(self, this: t.Optional[exp.Expression], is_global: bool = False) -> exp.In:
    397            this = super()._parse_in(this)
    398            this.set("is_global", is_global)
    399            return this
    400
    401        def _parse_table(
    402            self,
    403            schema: bool = False,
    404            joins: bool = False,
    405            alias_tokens: t.Optional[t.Collection[TokenType]] = None,
    406            parse_bracket: bool = False,
    407            is_db_reference: bool = False,
    408            parse_partition: bool = False,
    409        ) -> t.Optional[exp.Expression]:
    410            this = super()._parse_table(
    411                schema=schema,
    412                joins=joins,
    413                alias_tokens=alias_tokens,
    414                parse_bracket=parse_bracket,
    415                is_db_reference=is_db_reference,
    416            )
    417
    418            if self._match(TokenType.FINAL):
    419                this = self.expression(exp.Final, this=this)
    420
    421            return this
    422
    423        def _parse_position(self, haystack_first: bool = False) -> exp.StrPosition:
    424            return super()._parse_position(haystack_first=True)
    425
    426        # https://clickhouse.com/docs/en/sql-reference/statements/select/with/
    427        def _parse_cte(self) -> exp.CTE:
    428            # WITH <identifier> AS <subquery expression>
    429            cte: t.Optional[exp.CTE] = self._try_parse(super()._parse_cte)
    430
    431            if not cte:
    432                # WITH <expression> AS <identifier>
    433                cte = self.expression(
    434                    exp.CTE,
    435                    this=self._parse_conjunction(),
    436                    alias=self._parse_table_alias(),
    437                    scalar=True,
    438                )
    439
    440            return cte
    441
    442        def _parse_join_parts(
    443            self,
    444        ) -> t.Tuple[t.Optional[Token], t.Optional[Token], t.Optional[Token]]:
    445            is_global = self._match(TokenType.GLOBAL) and self._prev
    446            kind_pre = self._match_set(self.JOIN_KINDS, advance=False) and self._prev
    447
    448            if kind_pre:
    449                kind = self._match_set(self.JOIN_KINDS) and self._prev
    450                side = self._match_set(self.JOIN_SIDES) and self._prev
    451                return is_global, side, kind
    452
    453            return (
    454                is_global,
    455                self._match_set(self.JOIN_SIDES) and self._prev,
    456                self._match_set(self.JOIN_KINDS) and self._prev,
    457            )
    458
    459        def _parse_join(
    460            self, skip_join_token: bool = False, parse_bracket: bool = False
    461        ) -> t.Optional[exp.Join]:
    462            join = super()._parse_join(skip_join_token=skip_join_token, parse_bracket=True)
    463            if join:
    464                join.set("global", join.args.pop("method", None))
    465
    466            return join
    467
    468        def _parse_function(
    469            self,
    470            functions: t.Optional[t.Dict[str, t.Callable]] = None,
    471            anonymous: bool = False,
    472            optional_parens: bool = True,
    473            any_token: bool = False,
    474        ) -> t.Optional[exp.Expression]:
    475            expr = super()._parse_function(
    476                functions=functions,
    477                anonymous=anonymous,
    478                optional_parens=optional_parens,
    479                any_token=any_token,
    480            )
    481
    482            func = expr.this if isinstance(expr, exp.Window) else expr
    483
    484            # Aggregate functions can be split in 2 parts: <func_name><suffix>
    485            parts = (
    486                self.AGG_FUNC_MAPPING.get(func.this) if isinstance(func, exp.Anonymous) else None
    487            )
    488
    489            if parts:
    490                params = self._parse_func_params(func)
    491
    492                kwargs = {
    493                    "this": func.this,
    494                    "expressions": func.expressions,
    495                }
    496                if parts[1]:
    497                    kwargs["parts"] = parts
    498                    exp_class = exp.CombinedParameterizedAgg if params else exp.CombinedAggFunc
    499                else:
    500                    exp_class = exp.ParameterizedAgg if params else exp.AnonymousAggFunc
    501
    502                kwargs["exp_class"] = exp_class
    503                if params:
    504                    kwargs["params"] = params
    505
    506                func = self.expression(**kwargs)
    507
    508                if isinstance(expr, exp.Window):
    509                    # The window's func was parsed as Anonymous in base parser, fix its
    510                    # type to be CH style CombinedAnonymousAggFunc / AnonymousAggFunc
    511                    expr.set("this", func)
    512                elif params:
    513                    # Params have blocked super()._parse_function() from parsing the following window
    514                    # (if that exists) as they're standing between the function call and the window spec
    515                    expr = self._parse_window(func)
    516                else:
    517                    expr = func
    518
    519            return expr
    520
    521        def _parse_func_params(
    522            self, this: t.Optional[exp.Func] = None
    523        ) -> t.Optional[t.List[exp.Expression]]:
    524            if self._match_pair(TokenType.R_PAREN, TokenType.L_PAREN):
    525                return self._parse_csv(self._parse_lambda)
    526
    527            if self._match(TokenType.L_PAREN):
    528                params = self._parse_csv(self._parse_lambda)
    529                self._match_r_paren(this)
    530                return params
    531
    532            return None
    533
    534        def _parse_quantile(self) -> exp.Quantile:
    535            this = self._parse_lambda()
    536            params = self._parse_func_params()
    537            if params:
    538                return self.expression(exp.Quantile, this=params[0], quantile=this)
    539            return self.expression(exp.Quantile, this=this, quantile=exp.Literal.number(0.5))
    540
    541        def _parse_wrapped_id_vars(self, optional: bool = False) -> t.List[exp.Expression]:
    542            return super()._parse_wrapped_id_vars(optional=True)
    543
    544        def _parse_primary_key(
    545            self, wrapped_optional: bool = False, in_props: bool = False
    546        ) -> exp.PrimaryKeyColumnConstraint | exp.PrimaryKey:
    547            return super()._parse_primary_key(
    548                wrapped_optional=wrapped_optional or in_props, in_props=in_props
    549            )
    550
    551        def _parse_on_property(self) -> t.Optional[exp.Expression]:
    552            index = self._index
    553            if self._match_text_seq("CLUSTER"):
    554                this = self._parse_id_var()
    555                if this:
    556                    return self.expression(exp.OnCluster, this=this)
    557                else:
    558                    self._retreat(index)
    559            return None
    560
    561        def _parse_index_constraint(
    562            self, kind: t.Optional[str] = None
    563        ) -> exp.IndexColumnConstraint:
    564            # INDEX name1 expr TYPE type1(args) GRANULARITY value
    565            this = self._parse_id_var()
    566            expression = self._parse_conjunction()
    567
    568            index_type = self._match_text_seq("TYPE") and (
    569                self._parse_function() or self._parse_var()
    570            )
    571
    572            granularity = self._match_text_seq("GRANULARITY") and self._parse_term()
    573
    574            return self.expression(
    575                exp.IndexColumnConstraint,
    576                this=this,
    577                expression=expression,
    578                index_type=index_type,
    579                granularity=granularity,
    580            )

Parser consumes a list of tokens produced by the Tokenizer and produces a parsed syntax tree.

###### Arguments:

- error_level: The desired error level. Default: ErrorLevel.IMMEDIATE
- error_message_context: The amount of context to capture from a query string when displaying the error message (in number of characters). Default: 100
- max_errors: Maximum number of error messages to include in a raised ParseError. This is only relevant if error_level is ErrorLevel.RAISE. Default: 3

MODIFIERS_ATTACHED_TO_UNION = False
INTERVAL_SPANS = False
FUNCTIONS = {'ABS': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Abs'>>, 'ADD_MONTHS': <bound method Func.from_arg_list of <class 'sqlglot.expressions.AddMonths'>>, 'ANONYMOUS_AGG_FUNC': <bound method Func.from_arg_list of <class 'sqlglot.expressions.AnonymousAggFunc'>>, 'ANY_VALUE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.AnyValue'>>, 'APPROX_DISTINCT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ApproxDistinct'>>, 'APPROX_COUNT_DISTINCT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ApproxDistinct'>>, 'APPROX_QUANTILE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ApproxQuantile'>>, 'APPROX_TOP_K': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ApproxTopK'>>, 'ARG_MAX': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ArgMax'>>, 'ARGMAX': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ArgMax'>>, 'MAX_BY': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ArgMax'>>, 'ARG_MIN': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ArgMin'>>, 'ARGMIN': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ArgMin'>>, 'MIN_BY': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ArgMin'>>, 'ARRAY': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Array'>>, 'ARRAY_AGG': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ArrayAgg'>>, 'ARRAY_ALL': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ArrayAll'>>, 'ARRAY_ANY': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ArrayAny'>>, 'ARRAY_CONCAT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ArrayConcat'>>, 'ARRAY_CAT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ArrayConcat'>>, 'ARRAY_CONTAINS': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ArrayContains'>>, 'FILTER': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ArrayFilter'>>, 'ARRAY_FILTER': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ArrayFilter'>>, 'ARRAY_OVERLAPS': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ArrayOverlaps'>>, 'ARRAY_SIZE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ArraySize'>>, 'ARRAY_LENGTH': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ArraySize'>>, 'ARRAY_SORT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ArraySort'>>, 'ARRAY_SUM': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ArraySum'>>, 'ARRAY_TO_STRING': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ArrayToString'>>, 'ARRAY_JOIN': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ArrayToString'>>, 'ARRAY_UNION_AGG': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ArrayUnionAgg'>>, 'ARRAY_UNIQUE_AGG': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ArrayUniqueAgg'>>, 'AVG': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Avg'>>, 'CASE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Case'>>, 'CAST': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Cast'>>, 'CAST_TO_STR_TYPE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.CastToStrType'>>, 'CBRT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Cbrt'>>, 'CEIL': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Ceil'>>, 'CEILING': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Ceil'>>, 'CHR': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Chr'>>, 'CHAR': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Chr'>>, 'COALESCE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Coalesce'>>, 'IFNULL': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Coalesce'>>, 'NVL': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Coalesce'>>, 'COLLATE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Collate'>>, 'COMBINED_AGG_FUNC': <bound method Func.from_arg_list of <class 'sqlglot.expressions.CombinedAggFunc'>>, 'COMBINED_PARAMETERIZED_AGG': <bound method Func.from_arg_list of <class 'sqlglot.expressions.CombinedParameterizedAgg'>>, 'CONCAT': <function Parser.<lambda>>, 'CONCAT_WS': <function Parser.<lambda>>, 'CONNECT_BY_ROOT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ConnectByRoot'>>, 'CONVERT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Convert'>>, 'CORR': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Corr'>>, 'COUNT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Count'>>, 'COUNT_IF': <bound method Func.from_arg_list of <class 'sqlglot.expressions.CountIf'>>, 'COUNTIF': <function _build_count_if>, 'COVAR_POP': <bound method Func.from_arg_list of <class 'sqlglot.expressions.CovarPop'>>, 'COVAR_SAMP': <bound method Func.from_arg_list of <class 'sqlglot.expressions.CovarSamp'>>, 'CURRENT_DATE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.CurrentDate'>>, 'CURRENT_DATETIME': <bound method Func.from_arg_list of <class 'sqlglot.expressions.CurrentDatetime'>>, 'CURRENT_TIME': <bound method Func.from_arg_list of <class 'sqlglot.expressions.CurrentTime'>>, 'CURRENT_TIMESTAMP': <bound method Func.from_arg_list of <class 'sqlglot.expressions.CurrentTimestamp'>>, 'CURRENT_USER': <bound method Func.from_arg_list of <class 'sqlglot.expressions.CurrentUser'>>, 'DATE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Date'>>, 'DATE_ADD': <function ClickHouse.Parser.<lambda>>, 'DATEDIFF': <function ClickHouse.Parser.<lambda>>, 'DATE_DIFF': <function ClickHouse.Parser.<lambda>>, 'DATE_FROM_PARTS': <bound method Func.from_arg_list of <class 'sqlglot.expressions.DateFromParts'>>, 'DATEFROMPARTS': <bound method Func.from_arg_list of <class 'sqlglot.expressions.DateFromParts'>>, 'DATE_STR_TO_DATE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.DateStrToDate'>>, 'DATE_SUB': <bound method Func.from_arg_list of <class 'sqlglot.expressions.DateSub'>>, 'DATE_TO_DATE_STR': <function Parser.<lambda>>, 'DATE_TO_DI': <bound method Func.from_arg_list of <class 'sqlglot.expressions.DateToDi'>>, 'DATE_TRUNC': <bound method Func.from_arg_list of <class 'sqlglot.expressions.DateTrunc'>>, 'DATETIME_ADD': <bound method Func.from_arg_list of <class 'sqlglot.expressions.DatetimeAdd'>>, 'DATETIME_DIFF': <bound method Func.from_arg_list of <class 'sqlglot.expressions.DatetimeDiff'>>, 'DATETIME_SUB': <bound method Func.from_arg_list of <class 'sqlglot.expressions.DatetimeSub'>>, 'DATETIME_TRUNC': <bound method Func.from_arg_list of <class 'sqlglot.expressions.DatetimeTrunc'>>, 'DAY': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Day'>>, 'DAY_OF_MONTH': <bound method Func.from_arg_list of <class 'sqlglot.expressions.DayOfMonth'>>, 'DAYOFMONTH': <bound method Func.from_arg_list of <class 'sqlglot.expressions.DayOfMonth'>>, 'DAY_OF_WEEK': <bound method Func.from_arg_list of <class 'sqlglot.expressions.DayOfWeek'>>, 'DAYOFWEEK': <bound method Func.from_arg_list of <class 'sqlglot.expressions.DayOfWeek'>>, 'DAY_OF_YEAR': <bound method Func.from_arg_list of <class 'sqlglot.expressions.DayOfYear'>>, 'DAYOFYEAR': <bound method Func.from_arg_list of <class 'sqlglot.expressions.DayOfYear'>>, 'DECODE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Decode'>>, 'DI_TO_DATE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.DiToDate'>>, 'ENCODE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Encode'>>, 'EXP': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Exp'>>, 'EXPLODE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Explode'>>, 'EXPLODE_OUTER': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ExplodeOuter'>>, 'EXTRACT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Extract'>>, 'FIRST': <bound method Func.from_arg_list of <class 'sqlglot.expressions.First'>>, 'FIRST_VALUE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.FirstValue'>>, 'FLATTEN': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Flatten'>>, 'FLOOR': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Floor'>>, 'FROM_BASE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.FromBase'>>, 'FROM_BASE64': <bound method Func.from_arg_list of <class 'sqlglot.expressions.FromBase64'>>, 'GENERATE_DATE_ARRAY': <bound method Func.from_arg_list of <class 'sqlglot.expressions.GenerateDateArray'>>, 'GENERATE_SERIES': <bound method Func.from_arg_list of <class 'sqlglot.expressions.GenerateSeries'>>, 'GREATEST': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Greatest'>>, 'GROUP_CONCAT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.GroupConcat'>>, 'HEX': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Hex'>>, 'HLL': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Hll'>>, 'IF': <bound method Func.from_arg_list of <class 'sqlglot.expressions.If'>>, 'IIF': <bound method Func.from_arg_list of <class 'sqlglot.expressions.If'>>, 'INITCAP': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Initcap'>>, 'IS_INF': <bound method Func.from_arg_list of <class 'sqlglot.expressions.IsInf'>>, 'ISINF': <bound method Func.from_arg_list of <class 'sqlglot.expressions.IsInf'>>, 'IS_NAN': <bound method Func.from_arg_list of <class 'sqlglot.expressions.IsNan'>>, 'ISNAN': <bound method Func.from_arg_list of <class 'sqlglot.expressions.IsNan'>>, 'J_S_O_N_ARRAY': <bound method Func.from_arg_list of <class 'sqlglot.expressions.JSONArray'>>, 'J_S_O_N_ARRAY_AGG': <bound method Func.from_arg_list of <class 'sqlglot.expressions.JSONArrayAgg'>>, 'JSON_ARRAY_CONTAINS': <bound method Func.from_arg_list of <class 'sqlglot.expressions.JSONArrayContains'>>, 'JSONB_EXTRACT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.JSONBExtract'>>, 'JSONB_EXTRACT_SCALAR': <bound method Func.from_arg_list of <class 'sqlglot.expressions.JSONBExtractScalar'>>, 'JSON_EXTRACT': <function build_extract_json_with_path.<locals>._builder>, 'JSON_EXTRACT_SCALAR': <function build_extract_json_with_path.<locals>._builder>, 'JSON_FORMAT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.JSONFormat'>>, 'J_S_O_N_OBJECT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.JSONObject'>>, 'J_S_O_N_OBJECT_AGG': <bound method Func.from_arg_list of <class 'sqlglot.expressions.JSONObjectAgg'>>, 'J_S_O_N_TABLE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.JSONTable'>>, 'LAG': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Lag'>>, 'LAST': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Last'>>, 'LAST_DAY': <bound method Func.from_arg_list of <class 'sqlglot.expressions.LastDay'>>, 'LAST_DAY_OF_MONTH': <bound method Func.from_arg_list of <class 'sqlglot.expressions.LastDay'>>, 'LAST_VALUE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.LastValue'>>, 'LEAD': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Lead'>>, 'LEAST': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Least'>>, 'LEFT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Left'>>, 'LENGTH': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Length'>>, 'LEN': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Length'>>, 'LEVENSHTEIN': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Levenshtein'>>, 'LN': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Ln'>>, 'LOG': <function build_logarithm>, 'LOGICAL_AND': <bound method Func.from_arg_list of <class 'sqlglot.expressions.LogicalAnd'>>, 'BOOL_AND': <bound method Func.from_arg_list of <class 'sqlglot.expressions.LogicalAnd'>>, 'BOOLAND_AGG': <bound method Func.from_arg_list of <class 'sqlglot.expressions.LogicalAnd'>>, 'LOGICAL_OR': <bound method Func.from_arg_list of <class 'sqlglot.expressions.LogicalOr'>>, 'BOOL_OR': <bound method Func.from_arg_list of <class 'sqlglot.expressions.LogicalOr'>>, 'BOOLOR_AGG': <bound method Func.from_arg_list of <class 'sqlglot.expressions.LogicalOr'>>, 'LOWER': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Lower'>>, 'LCASE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Lower'>>, 'MD5': <bound method Func.from_arg_list of <class 'sqlglot.expressions.MD5'>>, 'MD5_DIGEST': <bound method Func.from_arg_list of <class 'sqlglot.expressions.MD5Digest'>>, 'MAP': <function build_var_map>, 'MAP_FROM_ENTRIES': <bound method Func.from_arg_list of <class 'sqlglot.expressions.MapFromEntries'>>, 'MATCH_AGAINST': <bound method Func.from_arg_list of <class 'sqlglot.expressions.MatchAgainst'>>, 'MAX': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Max'>>, 'MIN': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Min'>>, 'MONTH': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Month'>>, 'MONTHS_BETWEEN': <bound method Func.from_arg_list of <class 'sqlglot.expressions.MonthsBetween'>>, 'NEXT_VALUE_FOR': <bound method Func.from_arg_list of <class 'sqlglot.expressions.NextValueFor'>>, 'NTH_VALUE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.NthValue'>>, 'NULLIF': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Nullif'>>, 'NUMBER_TO_STR': <bound method Func.from_arg_list of <class 'sqlglot.expressions.NumberToStr'>>, 'NVL2': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Nvl2'>>, 'OPEN_J_S_O_N': <bound method Func.from_arg_list of <class 'sqlglot.expressions.OpenJSON'>>, 'PARAMETERIZED_AGG': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ParameterizedAgg'>>, 'PARSE_JSON': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ParseJSON'>>, 'JSON_PARSE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ParseJSON'>>, 'PERCENTILE_CONT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.PercentileCont'>>, 'PERCENTILE_DISC': <bound method Func.from_arg_list of <class 'sqlglot.expressions.PercentileDisc'>>, 'POSEXPLODE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Posexplode'>>, 'POSEXPLODE_OUTER': <bound method Func.from_arg_list of <class 'sqlglot.expressions.PosexplodeOuter'>>, 'POWER': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Pow'>>, 'POW': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Pow'>>, 'PREDICT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Predict'>>, 'QUANTILE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Quantile'>>, 'QUARTER': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Quarter'>>, 'RAND': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Rand'>>, 'RANDOM': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Rand'>>, 'RANDN': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Randn'>>, 'RANGE_N': <bound method Func.from_arg_list of <class 'sqlglot.expressions.RangeN'>>, 'READ_CSV': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ReadCSV'>>, 'REDUCE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Reduce'>>, 'REGEXP_EXTRACT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.RegexpExtract'>>, 'REGEXP_I_LIKE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.RegexpILike'>>, 'REGEXP_LIKE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.RegexpLike'>>, 'REGEXP_REPLACE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.RegexpReplace'>>, 'REGEXP_SPLIT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.RegexpSplit'>>, 'REPEAT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Repeat'>>, 'RIGHT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Right'>>, 'ROUND': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Round'>>, 'ROW_NUMBER': <bound method Func.from_arg_list of <class 'sqlglot.expressions.RowNumber'>>, 'SHA': <bound method Func.from_arg_list of <class 'sqlglot.expressions.SHA'>>, 'SHA1': <bound method Func.from_arg_list of <class 'sqlglot.expressions.SHA'>>, 'SHA2': <bound method Func.from_arg_list of <class 'sqlglot.expressions.SHA2'>>, 'SAFE_DIVIDE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.SafeDivide'>>, 'SIGN': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Sign'>>, 'SIGNUM': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Sign'>>, 'SORT_ARRAY': <bound method Func.from_arg_list of <class 'sqlglot.expressions.SortArray'>>, 'SPLIT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Split'>>, 'SQRT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Sqrt'>>, 'STANDARD_HASH': <bound method Func.from_arg_list of <class 'sqlglot.expressions.StandardHash'>>, 'STAR_MAP': <bound method Func.from_arg_list of <class 'sqlglot.expressions.StarMap'>>, 'STARTS_WITH': <bound method Func.from_arg_list of <class 'sqlglot.expressions.StartsWith'>>, 'STARTSWITH': <bound method Func.from_arg_list of <class 'sqlglot.expressions.StartsWith'>>, 'STDDEV': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Stddev'>>, 'STDDEV_POP': <bound method Func.from_arg_list of <class 'sqlglot.expressions.StddevPop'>>, 'STDDEV_SAMP': <bound method Func.from_arg_list of <class 'sqlglot.expressions.StddevSamp'>>, 'STR_POSITION': <bound method Func.from_arg_list of <class 'sqlglot.expressions.StrPosition'>>, 'STR_TO_DATE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.StrToDate'>>, 'STR_TO_MAP': <bound method Func.from_arg_list of <class 'sqlglot.expressions.StrToMap'>>, 'STR_TO_TIME': <bound method Func.from_arg_list of <class 'sqlglot.expressions.StrToTime'>>, 'STR_TO_UNIX': <bound method Func.from_arg_list of <class 'sqlglot.expressions.StrToUnix'>>, 'STRUCT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Struct'>>, 'STRUCT_EXTRACT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.StructExtract'>>, 'STUFF': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Stuff'>>, 'INSERT': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Stuff'>>, 'SUBSTRING': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Substring'>>, 'SUM': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Sum'>>, 'TIME_ADD': <bound method Func.from_arg_list of <class 'sqlglot.expressions.TimeAdd'>>, 'TIME_DIFF': <bound method Func.from_arg_list of <class 'sqlglot.expressions.TimeDiff'>>, 'TIME_FROM_PARTS': <bound method Func.from_arg_list of <class 'sqlglot.expressions.TimeFromParts'>>, 'TIMEFROMPARTS': <bound method Func.from_arg_list of <class 'sqlglot.expressions.TimeFromParts'>>, 'TIME_STR_TO_DATE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.TimeStrToDate'>>, 'TIME_STR_TO_TIME': <bound method Func.from_arg_list of <class 'sqlglot.expressions.TimeStrToTime'>>, 'TIME_STR_TO_UNIX': <bound method Func.from_arg_list of <class 'sqlglot.expressions.TimeStrToUnix'>>, 'TIME_SUB': <bound method Func.from_arg_list of <class 'sqlglot.expressions.TimeSub'>>, 'TIME_TO_STR': <bound method Func.from_arg_list of <class 'sqlglot.expressions.TimeToStr'>>, 'TIME_TO_TIME_STR': <function Parser.<lambda>>, 'TIME_TO_UNIX': <bound method Func.from_arg_list of <class 'sqlglot.expressions.TimeToUnix'>>, 'TIME_TRUNC': <bound method Func.from_arg_list of <class 'sqlglot.expressions.TimeTrunc'>>, 'TIMESTAMP': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Timestamp'>>, 'TIMESTAMP_ADD': <bound method Func.from_arg_list of <class 'sqlglot.expressions.TimestampAdd'>>, 'TIMESTAMPDIFF': <bound method Func.from_arg_list of <class 'sqlglot.expressions.TimestampDiff'>>, 'TIMESTAMP_DIFF': <bound method Func.from_arg_list of <class 'sqlglot.expressions.TimestampDiff'>>, 'TIMESTAMP_FROM_PARTS': <bound method Func.from_arg_list of <class 'sqlglot.expressions.TimestampFromParts'>>, 'TIMESTAMPFROMPARTS': <bound method Func.from_arg_list of <class 'sqlglot.expressions.TimestampFromParts'>>, 'TIMESTAMP_SUB': <bound method Func.from_arg_list of <class 'sqlglot.expressions.TimestampSub'>>, 'TIMESTAMP_TRUNC': <bound method Func.from_arg_list of <class 'sqlglot.expressions.TimestampTrunc'>>, 'TO_ARRAY': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ToArray'>>, 'TO_BASE64': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ToBase64'>>, 'TO_CHAR': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ToChar'>>, 'TO_DAYS': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ToDays'>>, 'TO_MAP': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ToMap'>>, 'TO_NUMBER': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ToNumber'>>, 'TRANSFORM': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Transform'>>, 'TRIM': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Trim'>>, 'TRY': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Try'>>, 'TRY_CAST': <bound method Func.from_arg_list of <class 'sqlglot.expressions.TryCast'>>, 'TS_OR_DI_TO_DI': <bound method Func.from_arg_list of <class 'sqlglot.expressions.TsOrDiToDi'>>, 'TS_OR_DS_ADD': <bound method Func.from_arg_list of <class 'sqlglot.expressions.TsOrDsAdd'>>, 'TS_OR_DS_DIFF': <bound method Func.from_arg_list of <class 'sqlglot.expressions.TsOrDsDiff'>>, 'TS_OR_DS_TO_DATE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.TsOrDsToDate'>>, 'TS_OR_DS_TO_DATE_STR': <function Parser.<lambda>>, 'TS_OR_DS_TO_TIME': <bound method Func.from_arg_list of <class 'sqlglot.expressions.TsOrDsToTime'>>, 'TS_OR_DS_TO_TIMESTAMP': <bound method Func.from_arg_list of <class 'sqlglot.expressions.TsOrDsToTimestamp'>>, 'UNHEX': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Unhex'>>, 'UNIX_DATE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.UnixDate'>>, 'UNIX_TO_STR': <bound method Func.from_arg_list of <class 'sqlglot.expressions.UnixToStr'>>, 'UNIX_TO_TIME': <bound method Func.from_arg_list of <class 'sqlglot.expressions.UnixToTime'>>, 'UNIX_TO_TIME_STR': <bound method Func.from_arg_list of <class 'sqlglot.expressions.UnixToTimeStr'>>, 'UPPER': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Upper'>>, 'UCASE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Upper'>>, 'VAR_MAP': <function build_var_map>, 'VARIANCE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Variance'>>, 'VARIANCE_SAMP': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Variance'>>, 'VAR_SAMP': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Variance'>>, 'VARIANCE_POP': <bound method Func.from_arg_list of <class 'sqlglot.expressions.VariancePop'>>, 'VAR_POP': <bound method Func.from_arg_list of <class 'sqlglot.expressions.VariancePop'>>, 'WEEK': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Week'>>, 'WEEK_OF_YEAR': <bound method Func.from_arg_list of <class 'sqlglot.expressions.WeekOfYear'>>, 'WEEKOFYEAR': <bound method Func.from_arg_list of <class 'sqlglot.expressions.WeekOfYear'>>, 'WHEN': <bound method Func.from_arg_list of <class 'sqlglot.expressions.When'>>, 'X_M_L_TABLE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.XMLTable'>>, 'XOR': <function ClickHouse.Parser.<lambda>>, 'YEAR': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Year'>>, 'GLOB': <function Parser.<lambda>>, 'JSON_EXTRACT_PATH_TEXT': <function build_extract_json_with_path.<locals>._builder>, 'LIKE': <function build_like>, 'LOG2': <function Parser.<lambda>>, 'LOG10': <function Parser.<lambda>>, 'MOD': <function Parser.<lambda>>, 'ANY': <bound method Func.from_arg_list of <class 'sqlglot.expressions.AnyValue'>>, 'ARRAYSUM': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ArraySum'>>, 'DATEADD': <function ClickHouse.Parser.<lambda>>, 'DATE_FORMAT': <function _build_date_format>, 'FORMATDATETIME': <function _build_date_format>, 'JSONEXTRACTSTRING': <function build_json_extract_path.<locals>._builder>, 'MATCH': <bound method Func.from_arg_list of <class 'sqlglot.expressions.RegexpLike'>>, 'RANDCANONICAL': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Rand'>>, 'TUPLE': <bound method Func.from_arg_list of <class 'sqlglot.expressions.Struct'>>, 'UNIQ': <bound method Func.from_arg_list of <class 'sqlglot.expressions.ApproxDistinct'>>}
AGG_FUNCTIONS = {'sum', 'groupBitmapAnd', 'retention', 'maxMap', 'sumKahan', 'quantilesInterpolatedWeighted', 'anyHeavy', 'sequenceMatch', 'skewPop', 'sequenceCount', 'topK', 'deltaSum', 'quantileBFloat16Weighted', 'uniqExact', 'groupBitmapOr', 'quantilesTDigestWeighted', 'quantileExactHigh', 'argMin', 'rankCorr', 'covarSamp', 'studentTTest', 'meanZTest', 'uniqCombined64', 'median', 'last_value', 'kolmogorovSmirnovTest', 'groupArrayLast', 'quantilesExactHigh', 'cramersVBiasCorrected', 'quantileTimingWeighted', 'quantileTDigestWeighted', 'sumWithOverflow', 'quantilesGK', 'quantilesDeterministic', 'groupBitXor', 'groupArrayInsertAt', 'histogram', 'uniqHLL12', 'groupArrayMovingSum', 'varSamp', 'welchTTest', 'exponentialTimeDecayedAvg', 'groupArray', 'argMax', 'quantileDeterministic', 'categoricalInformationValue', 'deltaSumTimestamp', 'sumCount', 'quantilesExact', 'max', 'quantilesBFloat16', 'sparkBar', 'minMap', 'simpleLinearRegression', 'anyLast', 'groupUniqArray', 'groupBitmapXor', 'topKWeighted', 'quantilesTDigest', 'groupBitOr', 'groupArraySample', 'quantileTiming', 'quantiles', 'cramersV', 'stochasticLinearRegression', 'theilsU', 'varPop', 'stochasticLogisticRegression', 'sumMap', 'quantile', 'mannWhitneyUTest', 'uniqCombined', 'uniqUpTo', 'contingency', 'quantilesBFloat16Weighted', 'uniqTheta', 'quantilesExactWeighted', 'uniq', 'count', 'quantileTDigest', 'skewSamp', 'min', 'intervalLengthSum', 'corr', 'avg', 'quantilesExactLow', 'groupBitmap', 'exponentialMovingAverage', 'sequenceNextNode', 'first_value', 'maxIntersections', 'largestTriangleThreeBuckets', 'quantileExactWeighted', 'stddevSamp', 'groupBitAnd', 'kurtPop', 'quantileGK', 'entropy', 'stddevPop', 'boundingRatio', 'maxIntersectionsPosition', 'quantileExact', 'quantilesTiming', 'avgWeighted', 'quantileInterpolatedWeighted', 'quantilesTimingWeighted', 'quantileExactLow', 'windowFunnel', 'quantileBFloat16', 'any', 'kurtSamp', 'groupArrayMovingAvg', 'covarPop'}
AGG_FUNCTIONS_SUFFIXES = ['If', 'Array', 'ArrayIf', 'Map', 'SimpleState', 'State', 'Merge', 'MergeState', 'ForEach', 'Distinct', 'OrDefault', 'OrNull', 'Resample', 'ArgMin', 'ArgMax']
FUNC_TOKENS = {<TokenType.USMALLINT: 'USMALLINT'>, <TokenType.AGGREGATEFUNCTION: 'AGGREGATEFUNCTION'>, <TokenType.IDENTIFIER: 'IDENTIFIER'>, <TokenType.TINYINT: 'TINYINT'>, <TokenType.INT4RANGE: 'INT4RANGE'>, <TokenType.CHAR: 'CHAR'>, <TokenType.DATEMULTIRANGE: 'DATEMULTIRANGE'>, <TokenType.JSON: 'JSON'>, <TokenType.ENUM16: 'ENUM16'>, <TokenType.TIMESTAMP_MS: 'TIMESTAMP_MS'>, <TokenType.ISNULL: 'ISNULL'>, <TokenType.INSERT: 'INSERT'>, <TokenType.XOR: 'XOR'>, <TokenType.CURRENT_DATETIME: 'CURRENT_DATETIME'>, <TokenType.MEDIUMINT: 'MEDIUMINT'>, <TokenType.CURRENT_DATE: 'CURRENT_DATE'>, <TokenType.INET: 'INET'>, <TokenType.FIXEDSTRING: 'FIXEDSTRING'>, <TokenType.HLLSKETCH: 'HLLSKETCH'>, <TokenType.LONGTEXT: 'LONGTEXT'>, <TokenType.YEAR: 'YEAR'>, <TokenType.XML: 'XML'>, <TokenType.GLOB: 'GLOB'>, <TokenType.MEDIUMTEXT: 'MEDIUMTEXT'>, <TokenType.SMALLINT: 'SMALLINT'>, <TokenType.INT: 'INT'>, <TokenType.TSTZRANGE: 'TSTZRANGE'>, <TokenType.OFFSET: 'OFFSET'>, <TokenType.TSTZMULTIRANGE: 'TSTZMULTIRANGE'>, <TokenType.ARRAY: 'ARRAY'>, <TokenType.FLOAT: 'FLOAT'>, <TokenType.BOOLEAN: 'BOOLEAN'>, <TokenType.COMMAND: 'COMMAND'>, <TokenType.INDEX: 'INDEX'>, <TokenType.TINYBLOB: 'TINYBLOB'>, <TokenType.IPV6: 'IPV6'>, <TokenType.ROWVERSION: 'ROWVERSION'>, <TokenType.SIMPLEAGGREGATEFUNCTION: 'SIMPLEAGGREGATEFUNCTION'>, <TokenType.PSEUDO_TYPE: 'PSEUDO_TYPE'>, <TokenType.HSTORE: 'HSTORE'>, <TokenType.RIGHT: 'RIGHT'>, <TokenType.DATETIME: 'DATETIME'>, <TokenType.LIKE: 'LIKE'>, <TokenType.UBIGINT: 'UBIGINT'>, <TokenType.NVARCHAR: 'NVARCHAR'>, <TokenType.TSMULTIRANGE: 'TSMULTIRANGE'>, <TokenType.SMALLSERIAL: 'SMALLSERIAL'>, <TokenType.TIMETZ: 'TIMETZ'>, <TokenType.INT8MULTIRANGE: 'INT8MULTIRANGE'>, <TokenType.NULL: 'NULL'>, <TokenType.ROW: 'ROW'>, <TokenType.SET: 'SET'>, <TokenType.VARCHAR: 'VARCHAR'>, <TokenType.NUMMULTIRANGE: 'NUMMULTIRANGE'>, <TokenType.CURRENT_TIME: 'CURRENT_TIME'>, <TokenType.GEOGRAPHY: 'GEOGRAPHY'>, <TokenType.TABLE: 'TABLE'>, <TokenType.FILTER: 'FILTER'>, <TokenType.BPCHAR: 'BPCHAR'>, <TokenType.UINT: 'UINT'>, <TokenType.DATE: 'DATE'>, <TokenType.SEQUENCE: 'SEQUENCE'>, <TokenType.PRIMARY_KEY: 'PRIMARY_KEY'>, <TokenType.UTINYINT: 'UTINYINT'>, <TokenType.BIGDECIMAL: 'BIGDECIMAL'>, <TokenType.OBJECT: 'OBJECT'>, <TokenType.IPPREFIX: 'IPPREFIX'>, <TokenType.CURRENT_TIMESTAMP: 'CURRENT_TIMESTAMP'>, <TokenType.TDIGEST: 'TDIGEST'>, <TokenType.VAR: 'VAR'>, <TokenType.ALL: 'ALL'>, <TokenType.USERDEFINED: 'USERDEFINED'>, <TokenType.UINT256: 'UINT256'>, <TokenType.LEFT: 'LEFT'>, <TokenType.NCHAR: 'NCHAR'>, <TokenType.ENUM: 'ENUM'>, <TokenType.JSONB: 'JSONB'>, <TokenType.TIME: 'TIME'>, <TokenType.MEDIUMBLOB: 'MEDIUMBLOB'>, <TokenType.NUMRANGE: 'NUMRANGE'>, <TokenType.FIRST: 'FIRST'>, <TokenType.DATETIME64: 'DATETIME64'>, <TokenType.VARIANT: 'VARIANT'>, <TokenType.ANY: 'ANY'>, <TokenType.TIMESTAMPTZ: 'TIMESTAMPTZ'>, <TokenType.NAME: 'NAME'>, <TokenType.INTERVAL: 'INTERVAL'>, <TokenType.UNIQUEIDENTIFIER: 'UNIQUEIDENTIFIER'>, <TokenType.WINDOW: 'WINDOW'>, <TokenType.UNKNOWN: 'UNKNOWN'>, <TokenType.UINT128: 'UINT128'>, <TokenType.TIMESTAMPLTZ: 'TIMESTAMPLTZ'>, <TokenType.MERGE: 'MERGE'>, <TokenType.DOUBLE: 'DOUBLE'>, <TokenType.IPADDRESS: 'IPADDRESS'>, <TokenType.BINARY: 'BINARY'>, <TokenType.MAP: 'MAP'>, <TokenType.NESTED: 'NESTED'>, <TokenType.SOME: 'SOME'>, <TokenType.MONEY: 'MONEY'>, <TokenType.LONGBLOB: 'LONGBLOB'>, <TokenType.SMALLMONEY: 'SMALLMONEY'>, <TokenType.BIGSERIAL: 'BIGSERIAL'>, <TokenType.BIT: 'BIT'>, <TokenType.NULLABLE: 'NULLABLE'>, <TokenType.RLIKE: 'RLIKE'>, <TokenType.TIMESTAMP: 'TIMESTAMP'>, <TokenType.UMEDIUMINT: 'UMEDIUMINT'>, <TokenType.TIMESTAMPNTZ: 'TIMESTAMPNTZ'>, <TokenType.CURRENT_USER: 'CURRENT_USER'>, <TokenType.VARBINARY: 'VARBINARY'>, <TokenType.EXISTS: 'EXISTS'>, <TokenType.COLLATE: 'COLLATE'>, <TokenType.INT256: 'INT256'>, <TokenType.REPLACE: 'REPLACE'>, <TokenType.BIGINT: 'BIGINT'>, <TokenType.TINYTEXT: 'TINYTEXT'>, <TokenType.SERIAL: 'SERIAL'>, <TokenType.TSRANGE: 'TSRANGE'>, <TokenType.ENUM8: 'ENUM8'>, <TokenType.TEXT: 'TEXT'>, <TokenType.SUPER: 'SUPER'>, <TokenType.DATERANGE: 'DATERANGE'>, <TokenType.DECIMAL: 'DECIMAL'>, <TokenType.STRUCT: 'STRUCT'>, <TokenType.FORMAT: 'FORMAT'>, <TokenType.OBJECT_IDENTIFIER: 'OBJECT_IDENTIFIER'>, <TokenType.INT8RANGE: 'INT8RANGE'>, <TokenType.UDECIMAL: 'UDECIMAL'>, <TokenType.TIMESTAMP_NS: 'TIMESTAMP_NS'>, <TokenType.INT128: 'INT128'>, <TokenType.UUID: 'UUID'>, <TokenType.RANGE: 'RANGE'>, <TokenType.ILIKE: 'ILIKE'>, <TokenType.UNNEST: 'UNNEST'>, <TokenType.IPV4: 'IPV4'>, <TokenType.DATE32: 'DATE32'>, <TokenType.INT4MULTIRANGE: 'INT4MULTIRANGE'>, <TokenType.TIMESTAMP_S: 'TIMESTAMP_S'>, <TokenType.GEOMETRY: 'GEOMETRY'>, <TokenType.TRUNCATE: 'TRUNCATE'>, <TokenType.LOWCARDINALITY: 'LOWCARDINALITY'>, <TokenType.IMAGE: 'IMAGE'>}
AGG_FUNC_MAPPING = {'sumIf': ('sum', 'If'), 'groupBitmapAndIf': ('groupBitmapAnd', 'If'), 'retentionIf': ('retention', 'If'), 'maxMapIf': ('maxMap', 'If'), 'sumKahanIf': ('sumKahan', 'If'), 'quantilesInterpolatedWeightedIf': ('quantilesInterpolatedWeighted', 'If'), 'anyHeavyIf': ('anyHeavy', 'If'), 'sequenceMatchIf': ('sequenceMatch', 'If'), 'skewPopIf': ('skewPop', 'If'), 'sequenceCountIf': ('sequenceCount', 'If'), 'topKIf': ('topK', 'If'), 'deltaSumIf': ('deltaSum', 'If'), 'quantileBFloat16WeightedIf': ('quantileBFloat16Weighted', 'If'), 'uniqExactIf': ('uniqExact', 'If'), 'groupBitmapOrIf': ('groupBitmapOr', 'If'), 'quantilesTDigestWeightedIf': ('quantilesTDigestWeighted', 'If'), 'quantileExactHighIf': ('quantileExactHigh', 'If'), 'argMinIf': ('argMin', 'If'), 'rankCorrIf': ('rankCorr', 'If'), 'covarSampIf': ('covarSamp', 'If'), 'studentTTestIf': ('studentTTest', 'If'), 'meanZTestIf': ('meanZTest', 'If'), 'uniqCombined64If': ('uniqCombined64', 'If'), 'medianIf': ('median', 'If'), 'last_valueIf': ('last_value', 'If'), 'kolmogorovSmirnovTestIf': ('kolmogorovSmirnovTest', 'If'), 'groupArrayLastIf': ('groupArrayLast', 'If'), 'quantilesExactHighIf': ('quantilesExactHigh', 'If'), 'cramersVBiasCorrectedIf': ('cramersVBiasCorrected', 'If'), 'quantileTimingWeightedIf': ('quantileTimingWeighted', 'If'), 'quantileTDigestWeightedIf': ('quantileTDigestWeighted', 'If'), 'sumWithOverflowIf': ('sumWithOverflow', 'If'), 'quantilesGKIf': ('quantilesGK', 'If'), 'quantilesDeterministicIf': ('quantilesDeterministic', 'If'), 'groupBitXorIf': ('groupBitXor', 'If'), 'groupArrayInsertAtIf': ('groupArrayInsertAt', 'If'), 'histogramIf': ('histogram', 'If'), 'uniqHLL12If': ('uniqHLL12', 'If'), 'groupArrayMovingSumIf': ('groupArrayMovingSum', 'If'), 'varSampIf': ('varSamp', 'If'), 'welchTTestIf': ('welchTTest', 'If'), 'exponentialTimeDecayedAvgIf': ('exponentialTimeDecayedAvg', 'If'), 'groupArrayIf': ('groupArray', 'If'), 'argMaxIf': ('argMax', 'If'), 'quantileDeterministicIf': ('quantileDeterministic', 'If'), 'categoricalInformationValueIf': ('categoricalInformationValue', 'If'), 'deltaSumTimestampIf': ('deltaSumTimestamp', 'If'), 'sumCountIf': ('sumCount', 'If'), 'quantilesExactIf': ('quantilesExact', 'If'), 'maxIf': ('max', 'If'), 'quantilesBFloat16If': ('quantilesBFloat16', 'If'), 'sparkBarIf': ('sparkBar', 'If'), 'minMapIf': ('minMap', 'If'), 'simpleLinearRegressionIf': ('simpleLinearRegression', 'If'), 'anyLastIf': ('anyLast', 'If'), 'groupUniqArrayIf': ('groupUniqArray', 'If'), 'groupBitmapXorIf': ('groupBitmapXor', 'If'), 'topKWeightedIf': ('topKWeighted', 'If'), 'quantilesTDigestIf': ('quantilesTDigest', 'If'), 'groupBitOrIf': ('groupBitOr', 'If'), 'groupArraySampleIf': ('groupArraySample', 'If'), 'quantileTimingIf': ('quantileTiming', 'If'), 'quantilesIf': ('quantiles', 'If'), 'cramersVIf': ('cramersV', 'If'), 'stochasticLinearRegressionIf': ('stochasticLinearRegression', 'If'), 'theilsUIf': ('theilsU', 'If'), 'varPopIf': ('varPop', 'If'), 'stochasticLogisticRegressionIf': ('stochasticLogisticRegression', 'If'), 'sumMapIf': ('sumMap', 'If'), 'quantileIf': ('quantile', 'If'), 'mannWhitneyUTestIf': ('mannWhitneyUTest', 'If'), 'uniqCombinedIf': ('uniqCombined', 'If'), 'uniqUpToIf': ('uniqUpTo', 'If'), 'contingencyIf': ('contingency', 'If'), 'quantilesBFloat16WeightedIf': ('quantilesBFloat16Weighted', 'If'), 'uniqThetaIf': ('uniqTheta', 'If'), 'quantilesExactWeightedIf': ('quantilesExactWeighted', 'If'), 'uniqIf': ('uniq', 'If'), 'countIf': ('count', 'If'), 'quantileTDigestIf': ('quantileTDigest', 'If'), 'skewSampIf': ('skewSamp', 'If'), 'minIf': ('min', 'If'), 'intervalLengthSumIf': ('intervalLengthSum', 'If'), 'corrIf': ('corr', 'If'), 'avgIf': ('avg', 'If'), 'quantilesExactLowIf': ('quantilesExactLow', 'If'), 'groupBitmapIf': ('groupBitmap', 'If'), 'exponentialMovingAverageIf': ('exponentialMovingAverage', 'If'), 'sequenceNextNodeIf': ('sequenceNextNode', 'If'), 'first_valueIf': ('first_value', 'If'), 'maxIntersectionsIf': ('maxIntersections', 'If'), 'largestTriangleThreeBucketsIf': ('largestTriangleThreeBuckets', 'If'), 'quantileExactWeightedIf': ('quantileExactWeighted', 'If'), 'stddevSampIf': ('stddevSamp', 'If'), 'groupBitAndIf': ('groupBitAnd', 'If'), 'kurtPopIf': ('kurtPop', 'If'), 'quantileGKIf': ('quantileGK', 'If'), 'entropyIf': ('entropy', 'If'), 'stddevPopIf': ('stddevPop', 'If'), 'boundingRatioIf': ('boundingRatio', 'If'), 'maxIntersectionsPositionIf': ('maxIntersectionsPosition', 'If'), 'quantileExactIf': ('quantileExact', 'If'), 'quantilesTimingIf': ('quantilesTiming', 'If'), 'avgWeightedIf': ('avgWeighted', 'If'), 'quantileInterpolatedWeightedIf': ('quantileInterpolatedWeighted', 'If'), 'quantilesTimingWeightedIf': ('quantilesTimingWeighted', 'If'), 'quantileExactLowIf': ('quantileExactLow', 'If'), 'windowFunnelIf': ('windowFunnel', 'If'), 'quantileBFloat16If': ('quantileBFloat16', 'If'), 'anyIf': ('any', 'If'), 'kurtSampIf': ('kurtSamp', 'If'), 'groupArrayMovingAvgIf': ('groupArrayMovingAvg', 'If'), 'covarPopIf': ('covarPop', 'If'), 'sumArray': ('sum', 'Array'), 'groupBitmapAndArray': ('groupBitmapAnd', 'Array'), 'retentionArray': ('retention', 'Array'), 'maxMapArray': ('maxMap', 'Array'), 'sumKahanArray': ('sumKahan', 'Array'), 'quantilesInterpolatedWeightedArray': ('quantilesInterpolatedWeighted', 'Array'), 'anyHeavyArray': ('anyHeavy', 'Array'), 'sequenceMatchArray': ('sequenceMatch', 'Array'), 'skewPopArray': ('skewPop', 'Array'), 'sequenceCountArray': ('sequenceCount', 'Array'), 'topKArray': ('topK', 'Array'), 'deltaSumArray': ('deltaSum', 'Array'), 'quantileBFloat16WeightedArray': ('quantileBFloat16Weighted', 'Array'), 'uniqExactArray': ('uniqExact', 'Array'), 'groupBitmapOrArray': ('groupBitmapOr', 'Array'), 'quantilesTDigestWeightedArray': ('quantilesTDigestWeighted', 'Array'), 'quantileExactHighArray': ('quantileExactHigh', 'Array'), 'argMinArray': ('argMin', 'Array'), 'rankCorrArray': ('rankCorr', 'Array'), 'covarSampArray': ('covarSamp', 'Array'), 'studentTTestArray': ('studentTTest', 'Array'), 'meanZTestArray': ('meanZTest', 'Array'), 'uniqCombined64Array': ('uniqCombined64', 'Array'), 'medianArray': ('median', 'Array'), 'last_valueArray': ('last_value', 'Array'), 'kolmogorovSmirnovTestArray': ('kolmogorovSmirnovTest', 'Array'), 'groupArrayLastArray': ('groupArrayLast', 'Array'), 'quantilesExactHighArray': ('quantilesExactHigh', 'Array'), 'cramersVBiasCorrectedArray': ('cramersVBiasCorrected', 'Array'), 'quantileTimingWeightedArray': ('quantileTimingWeighted', 'Array'), 'quantileTDigestWeightedArray': ('quantileTDigestWeighted', 'Array'), 'sumWithOverflowArray': ('sumWithOverflow', 'Array'), 'quantilesGKArray': ('quantilesGK', 'Array'), 'quantilesDeterministicArray': ('quantilesDeterministic', 'Array'), 'groupBitXorArray': ('groupBitXor', 'Array'), 'groupArrayInsertAtArray': ('groupArrayInsertAt', 'Array'), 'histogramArray': ('histogram', 'Array'), 'uniqHLL12Array': ('uniqHLL12', 'Array'), 'groupArrayMovingSumArray': ('groupArrayMovingSum', 'Array'), 'varSampArray': ('varSamp', 'Array'), 'welchTTestArray': ('welchTTest', 'Array'), 'exponentialTimeDecayedAvgArray': ('exponentialTimeDecayedAvg', 'Array'), 'groupArrayArray': ('groupArray', 'Array'), 'argMaxArray': ('argMax', 'Array'), 'quantileDeterministicArray': ('quantileDeterministic', 'Array'), 'categoricalInformationValueArray': ('categoricalInformationValue', 'Array'), 'deltaSumTimestampArray': ('deltaSumTimestamp', 'Array'), 'sumCountArray': ('sumCount', 'Array'), 'quantilesExactArray': ('quantilesExact', 'Array'), 'maxArray': ('max', 'Array'), 'quantilesBFloat16Array': ('quantilesBFloat16', 'Array'), 'sparkBarArray': ('sparkBar', 'Array'), 'minMapArray': ('minMap', 'Array'), 'simpleLinearRegressionArray': ('simpleLinearRegression', 'Array'), 'anyLastArray': ('anyLast', 'Array'), 'groupUniqArrayArray': ('groupUniqArray', 'Array'), 'groupBitmapXorArray': ('groupBitmapXor', 'Array'), 'topKWeightedArray': ('topKWeighted', 'Array'), 'quantilesTDigestArray': ('quantilesTDigest', 'Array'), 'groupBitOrArray': ('groupBitOr', 'Array'), 'groupArraySampleArray': ('groupArraySample', 'Array'), 'quantileTimingArray': ('quantileTiming', 'Array'), 'quantilesArray': ('quantiles', 'Array'), 'cramersVArray': ('cramersV', 'Array'), 'stochasticLinearRegressionArray': ('stochasticLinearRegression', 'Array'), 'theilsUArray': ('theilsU', 'Array'), 'varPopArray': ('varPop', 'Array'), 'stochasticLogisticRegressionArray': ('stochasticLogisticRegression', 'Array'), 'sumMapArray': ('sumMap', 'Array'), 'quantileArray': ('quantile', 'Array'), 'mannWhitneyUTestArray': ('mannWhitneyUTest', 'Array'), 'uniqCombinedArray': ('uniqCombined', 'Array'), 'uniqUpToArray': ('uniqUpTo', 'Array'), 'contingencyArray': ('contingency', 'Array'), 'quantilesBFloat16WeightedArray': ('quantilesBFloat16Weighted', 'Array'), 'uniqThetaArray': ('uniqTheta', 'Array'), 'quantilesExactWeightedArray': ('quantilesExactWeighted', 'Array'), 'uniqArray': ('uniq', 'Array'), 'countArray': ('count', 'Array'), 'quantileTDigestArray': ('quantileTDigest', 'Array'), 'skewSampArray': ('skewSamp', 'Array'), 'minArray': ('min', 'Array'), 'intervalLengthSumArray': ('intervalLengthSum', 'Array'), 'corrArray': ('corr', 'Array'), 'avgArray': ('avg', 'Array'), 'quantilesExactLowArray': ('quantilesExactLow', 'Array'), 'groupBitmapArray': ('groupBitmap', 'Array'), 'exponentialMovingAverageArray': ('exponentialMovingAverage', 'Array'), 'sequenceNextNodeArray': ('sequenceNextNode', 'Array'), 'first_valueArray': ('first_value', 'Array'), 'maxIntersectionsArray': ('maxIntersections', 'Array'), 'largestTriangleThreeBucketsArray': ('largestTriangleThreeBuckets', 'Array'), 'quantileExactWeightedArray': ('quantileExactWeighted', 'Array'), 'stddevSampArray': ('stddevSamp', 'Array'), 'groupBitAndArray': ('groupBitAnd', 'Array'), 'kurtPopArray': ('kurtPop', 'Array'), 'quantileGKArray': ('quantileGK', 'Array'), 'entropyArray': ('entropy', 'Array'), 'stddevPopArray': ('stddevPop', 'Array'), 'boundingRatioArray': ('boundingRatio', 'Array'), 'maxIntersectionsPositionArray': ('maxIntersectionsPosition', 'Array'), 'quantileExactArray': ('quantileExact', 'Array'), 'quantilesTimingArray': ('quantilesTiming', 'Array'), 'avgWeightedArray': ('avgWeighted', 'Array'), 'quantileInterpolatedWeightedArray': ('quantileInterpolatedWeighted', 'Array'), 'quantilesTimingWeightedArray': ('quantilesTimingWeighted', 'Array'), 'quantileExactLowArray': ('quantileExactLow', 'Array'), 'windowFunnelArray': ('windowFunnel', 'Array'), 'quantileBFloat16Array': ('quantileBFloat16', 'Array'), 'anyArray': ('any', 'Array'), 'kurtSampArray': ('kurtSamp', 'Array'), 'groupArrayMovingAvgArray': ('groupArrayMovingAvg', 'Array'), 'covarPopArray': ('covarPop', 'Array'), 'sumArrayIf': ('sum', 'ArrayIf'), 'groupBitmapAndArrayIf': ('groupBitmapAnd', 'ArrayIf'), 'retentionArrayIf': ('retention', 'ArrayIf'), 'maxMapArrayIf': ('maxMap', 'ArrayIf'), 'sumKahanArrayIf': ('sumKahan', 'ArrayIf'), 'quantilesInterpolatedWeightedArrayIf': ('quantilesInterpolatedWeighted', 'ArrayIf'), 'anyHeavyArrayIf': ('anyHeavy', 'ArrayIf'), 'sequenceMatchArrayIf': ('sequenceMatch', 'ArrayIf'), 'skewPopArrayIf': ('skewPop', 'ArrayIf'), 'sequenceCountArrayIf': ('sequenceCount', 'ArrayIf'), 'topKArrayIf': ('topK', 'ArrayIf'), 'deltaSumArrayIf': ('deltaSum', 'ArrayIf'), 'quantileBFloat16WeightedArrayIf': ('quantileBFloat16Weighted', 'ArrayIf'), 'uniqExactArrayIf': ('uniqExact', 'ArrayIf'), 'groupBitmapOrArrayIf': ('groupBitmapOr', 'ArrayIf'), 'quantilesTDigestWeightedArrayIf': ('quantilesTDigestWeighted', 'ArrayIf'), 'quantileExactHighArrayIf': ('quantileExactHigh', 'ArrayIf'), 'argMinArrayIf': ('argMin', 'ArrayIf'), 'rankCorrArrayIf': ('rankCorr', 'ArrayIf'), 'covarSampArrayIf': ('covarSamp', 'ArrayIf'), 'studentTTestArrayIf': ('studentTTest', 'ArrayIf'), 'meanZTestArrayIf': ('meanZTest', 'ArrayIf'), 'uniqCombined64ArrayIf': ('uniqCombined64', 'ArrayIf'), 'medianArrayIf': ('median', 'ArrayIf'), 'last_valueArrayIf': ('last_value', 'ArrayIf'), 'kolmogorovSmirnovTestArrayIf': ('kolmogorovSmirnovTest', 'ArrayIf'), 'groupArrayLastArrayIf': ('groupArrayLast', 'ArrayIf'), 'quantilesExactHighArrayIf': ('quantilesExactHigh', 'ArrayIf'), 'cramersVBiasCorrectedArrayIf': ('cramersVBiasCorrected', 'ArrayIf'), 'quantileTimingWeightedArrayIf': ('quantileTimingWeighted', 'ArrayIf'), 'quantileTDigestWeightedArrayIf': ('quantileTDigestWeighted', 'ArrayIf'), 'sumWithOverflowArrayIf': ('sumWithOverflow', 'ArrayIf'), 'quantilesGKArrayIf': ('quantilesGK', 'ArrayIf'), 'quantilesDeterministicArrayIf': ('quantilesDeterministic', 'ArrayIf'), 'groupBitXorArrayIf': ('groupBitXor', 'ArrayIf'), 'groupArrayInsertAtArrayIf': ('groupArrayInsertAt', 'ArrayIf'), 'histogramArrayIf': ('histogram', 'ArrayIf'), 'uniqHLL12ArrayIf': ('uniqHLL12', 'ArrayIf'), 'groupArrayMovingSumArrayIf': ('groupArrayMovingSum', 'ArrayIf'), 'varSampArrayIf': ('varSamp', 'ArrayIf'), 'welchTTestArrayIf': ('welchTTest', 'ArrayIf'), 'exponentialTimeDecayedAvgArrayIf': ('exponentialTimeDecayedAvg', 'ArrayIf'), 'groupArrayArrayIf': ('groupArray', 'ArrayIf'), 'argMaxArrayIf': ('argMax', 'ArrayIf'), 'quantileDeterministicArrayIf': ('quantileDeterministic', 'ArrayIf'), 'categoricalInformationValueArrayIf': ('categoricalInformationValue', 'ArrayIf'), 'deltaSumTimestampArrayIf': ('deltaSumTimestamp', 'ArrayIf'), 'sumCountArrayIf': ('sumCount', 'ArrayIf'), 'quantilesExactArrayIf': ('quantilesExact', 'ArrayIf'), 'maxArrayIf': ('max', 'ArrayIf'), 'quantilesBFloat16ArrayIf': ('quantilesBFloat16', 'ArrayIf'), 'sparkBarArrayIf': ('sparkBar', 'ArrayIf'), 'minMapArrayIf': ('minMap', 'ArrayIf'), 'simpleLinearRegressionArrayIf': ('simpleLinearRegression', 'ArrayIf'), 'anyLastArrayIf': ('anyLast', 'ArrayIf'), 'groupUniqArrayArrayIf': ('groupUniqArray', 'ArrayIf'), 'groupBitmapXorArrayIf': ('groupBitmapXor', 'ArrayIf'), 'topKWeightedArrayIf': ('topKWeighted', 'ArrayIf'), 'quantilesTDigestArrayIf': ('quantilesTDigest', 'ArrayIf'), 'groupBitOrArrayIf': ('groupBitOr', 'ArrayIf'), 'groupArraySampleArrayIf': ('groupArraySample', 'ArrayIf'), 'quantileTimingArrayIf': ('quantileTiming', 'ArrayIf'), 'quantilesArrayIf': ('quantiles', 'ArrayIf'), 'cramersVArrayIf': ('cramersV', 'ArrayIf'), 'stochasticLinearRegressionArrayIf': ('stochasticLinearRegression', 'ArrayIf'), 'theilsUArrayIf': ('theilsU', 'ArrayIf'), 'varPopArrayIf': ('varPop', 'ArrayIf'), 'stochasticLogisticRegressionArrayIf': ('stochasticLogisticRegression', 'ArrayIf'), 'sumMapArrayIf': ('sumMap', 'ArrayIf'), 'quantileArrayIf': ('quantile', 'ArrayIf'), 'mannWhitneyUTestArrayIf': ('mannWhitneyUTest', 'ArrayIf'), 'uniqCombinedArrayIf': ('uniqCombined', 'ArrayIf'), 'uniqUpToArrayIf': ('uniqUpTo', 'ArrayIf'), 'contingencyArrayIf': ('contingency', 'ArrayIf'), 'quantilesBFloat16WeightedArrayIf': ('quantilesBFloat16Weighted', 'ArrayIf'), 'uniqThetaArrayIf': ('uniqTheta', 'ArrayIf'), 'quantilesExactWeightedArrayIf': ('quantilesExactWeighted', 'ArrayIf'), 'uniqArrayIf': ('uniq', 'ArrayIf'), 'countArrayIf': ('count', 'ArrayIf'), 'quantileTDigestArrayIf': ('quantileTDigest', 'ArrayIf'), 'skewSampArrayIf': ('skewSamp', 'ArrayIf'), 'minArrayIf': ('min', 'ArrayIf'), 'intervalLengthSumArrayIf': ('intervalLengthSum', 'ArrayIf'), 'corrArrayIf': ('corr', 'ArrayIf'), 'avgArrayIf': ('avg', 'ArrayIf'), 'quantilesExactLowArrayIf': ('quantilesExactLow', 'ArrayIf'), 'groupBitmapArrayIf': ('groupBitmap', 'ArrayIf'), 'exponentialMovingAverageArrayIf': ('exponentialMovingAverage', 'ArrayIf'), 'sequenceNextNodeArrayIf': ('sequenceNextNode', 'ArrayIf'), 'first_valueArrayIf': ('first_value', 'ArrayIf'), 'maxIntersectionsArrayIf': ('maxIntersections', 'ArrayIf'), 'largestTriangleThreeBucketsArrayIf': ('largestTriangleThreeBuckets', 'ArrayIf'), 'quantileExactWeightedArrayIf': ('quantileExactWeighted', 'ArrayIf'), 'stddevSampArrayIf': ('stddevSamp', 'ArrayIf'), 'groupBitAndArrayIf': ('groupBitAnd', 'ArrayIf'), 'kurtPopArrayIf': ('kurtPop', 'ArrayIf'), 'quantileGKArrayIf': ('quantileGK', 'ArrayIf'), 'entropyArrayIf': ('entropy', 'ArrayIf'), 'stddevPopArrayIf': ('stddevPop', 'ArrayIf'), 'boundingRatioArrayIf': ('boundingRatio', 'ArrayIf'), 'maxIntersectionsPositionArrayIf': ('maxIntersectionsPosition', 'ArrayIf'), 'quantileExactArrayIf': ('quantileExact', 'ArrayIf'), 'quantilesTimingArrayIf': ('quantilesTiming', 'ArrayIf'), 'avgWeightedArrayIf': ('avgWeighted', 'ArrayIf'), 'quantileInterpolatedWeightedArrayIf': ('quantileInterpolatedWeighted', 'ArrayIf'), 'quantilesTimingWeightedArrayIf': ('quantilesTimingWeighted', 'ArrayIf'), 'quantileExactLowArrayIf': ('quantileExactLow', 'ArrayIf'), 'windowFunnelArrayIf': ('windowFunnel', 'ArrayIf'), 'quantileBFloat16ArrayIf': ('quantileBFloat16', 'ArrayIf'), 'anyArrayIf': ('any', 'ArrayIf'), 'kurtSampArrayIf': ('kurtSamp', 'ArrayIf'), 'groupArrayMovingAvgArrayIf': ('groupArrayMovingAvg', 'ArrayIf'), 'covarPopArrayIf': ('covarPop', 'ArrayIf'), 'sumMap': ('sumMap', ''), 'groupBitmapAndMap': ('groupBitmapAnd', 'Map'), 'retentionMap': ('retention', 'Map'), 'maxMapMap': ('maxMap', 'Map'), 'sumKahanMap': ('sumKahan', 'Map'), 'quantilesInterpolatedWeightedMap': ('quantilesInterpolatedWeighted', 'Map'), 'anyHeavyMap': ('anyHeavy', 'Map'), 'sequenceMatchMap': ('sequenceMatch', 'Map'), 'skewPopMap': ('skewPop', 'Map'), 'sequenceCountMap': ('sequenceCount', 'Map'), 'topKMap': ('topK', 'Map'), 'deltaSumMap': ('deltaSum', 'Map'), 'quantileBFloat16WeightedMap': ('quantileBFloat16Weighted', 'Map'), 'uniqExactMap': ('uniqExact', 'Map'), 'groupBitmapOrMap': ('groupBitmapOr', 'Map'), 'quantilesTDigestWeightedMap': ('quantilesTDigestWeighted', 'Map'), 'quantileExactHighMap': ('quantileExactHigh', 'Map'), 'argMinMap': ('argMin', 'Map'), 'rankCorrMap': ('rankCorr', 'Map'), 'covarSampMap': ('covarSamp', 'Map'), 'studentTTestMap': ('studentTTest', 'Map'), 'meanZTestMap': ('meanZTest', 'Map'), 'uniqCombined64Map': ('uniqCombined64', 'Map'), 'medianMap': ('median', 'Map'), 'last_valueMap': ('last_value', 'Map'), 'kolmogorovSmirnovTestMap': ('kolmogorovSmirnovTest', 'Map'), 'groupArrayLastMap': ('groupArrayLast', 'Map'), 'quantilesExactHighMap': ('quantilesExactHigh', 'Map'), 'cramersVBiasCorrectedMap': ('cramersVBiasCorrected', 'Map'), 'quantileTimingWeightedMap': ('quantileTimingWeighted', 'Map'), 'quantileTDigestWeightedMap': ('quantileTDigestWeighted', 'Map'), 'sumWithOverflowMap': ('sumWithOverflow', 'Map'), 'quantilesGKMap': ('quantilesGK', 'Map'), 'quantilesDeterministicMap': ('quantilesDeterministic', 'Map'), 'groupBitXorMap': ('groupBitXor', 'Map'), 'groupArrayInsertAtMap': ('groupArrayInsertAt', 'Map'), 'histogramMap': ('histogram', 'Map'), 'uniqHLL12Map': ('uniqHLL12', 'Map'), 'groupArrayMovingSumMap': ('groupArrayMovingSum', 'Map'), 'varSampMap': ('varSamp', 'Map'), 'welchTTestMap': ('welchTTest', 'Map'), 'exponentialTimeDecayedAvgMap': ('exponentialTimeDecayedAvg', 'Map'), 'groupArrayMap': ('groupArray', 'Map'), 'argMaxMap': ('argMax', 'Map'), 'quantileDeterministicMap': ('quantileDeterministic', 'Map'), 'categoricalInformationValueMap': ('categoricalInformationValue', 'Map'), 'deltaSumTimestampMap': ('deltaSumTimestamp', 'Map'), 'sumCountMap': ('sumCount', 'Map'), 'quantilesExactMap': ('quantilesExact', 'Map'), 'maxMap': ('maxMap', ''), 'quantilesBFloat16Map': ('quantilesBFloat16', 'Map'), 'sparkBarMap': ('sparkBar', 'Map'), 'minMapMap': ('minMap', 'Map'), 'simpleLinearRegressionMap': ('simpleLinearRegression', 'Map'), 'anyLastMap': ('anyLast', 'Map'), 'groupUniqArrayMap': ('groupUniqArray', 'Map'), 'groupBitmapXorMap': ('groupBitmapXor', 'Map'), 'topKWeightedMap': ('topKWeighted', 'Map'), 'quantilesTDigestMap': ('quantilesTDigest', 'Map'), 'groupBitOrMap': ('groupBitOr', 'Map'), 'groupArraySampleMap': ('groupArraySample', 'Map'), 'quantileTimingMap': ('quantileTiming', 'Map'), 'quantilesMap': ('quantiles', 'Map'), 'cramersVMap': ('cramersV', 'Map'), 'stochasticLinearRegressionMap': ('stochasticLinearRegression', 'Map'), 'theilsUMap': ('theilsU', 'Map'), 'varPopMap': ('varPop', 'Map'), 'stochasticLogisticRegressionMap': ('stochasticLogisticRegression', 'Map'), 'sumMapMap': ('sumMap', 'Map'), 'quantileMap': ('quantile', 'Map'), 'mannWhitneyUTestMap': ('mannWhitneyUTest', 'Map'), 'uniqCombinedMap': ('uniqCombined', 'Map'), 'uniqUpToMap': ('uniqUpTo', 'Map'), 'contingencyMap': ('contingency', 'Map'), 'quantilesBFloat16WeightedMap': ('quantilesBFloat16Weighted', 'Map'), 'uniqThetaMap': ('uniqTheta', 'Map'), 'quantilesExactWeightedMap': ('quantilesExactWeighted', 'Map'), 'uniqMap': ('uniq', 'Map'), 'countMap': ('count', 'Map'), 'quantileTDigestMap': ('quantileTDigest', 'Map'), 'skewSampMap': ('skewSamp', 'Map'), 'minMap': ('minMap', ''), 'intervalLengthSumMap': ('intervalLengthSum', 'Map'), 'corrMap': ('corr', 'Map'), 'avgMap': ('avg', 'Map'), 'quantilesExactLowMap': ('quantilesExactLow', 'Map'), 'groupBitmapMap': ('groupBitmap', 'Map'), 'exponentialMovingAverageMap': ('exponentialMovingAverage', 'Map'), 'sequenceNextNodeMap': ('sequenceNextNode', 'Map'), 'first_valueMap': ('first_value', 'Map'), 'maxIntersectionsMap': ('maxIntersections', 'Map'), 'largestTriangleThreeBucketsMap': ('largestTriangleThreeBuckets', 'Map'), 'quantileExactWeightedMap': ('quantileExactWeighted', 'Map'), 'stddevSampMap': ('stddevSamp', 'Map'), 'groupBitAndMap': ('groupBitAnd', 'Map'), 'kurtPopMap': ('kurtPop', 'Map'), 'quantileGKMap': ('quantileGK', 'Map'), 'entropyMap': ('entropy', 'Map'), 'stddevPopMap': ('stddevPop', 'Map'), 'boundingRatioMap': ('boundingRatio', 'Map'), 'maxIntersectionsPositionMap': ('maxIntersectionsPosition', 'Map'), 'quantileExactMap': ('quantileExact', 'Map'), 'quantilesTimingMap': ('quantilesTiming', 'Map'), 'avgWeightedMap': ('avgWeighted', 'Map'), 'quantileInterpolatedWeightedMap': ('quantileInterpolatedWeighted', 'Map'), 'quantilesTimingWeightedMap': ('quantilesTimingWeighted', 'Map'), 'quantileExactLowMap': ('quantileExactLow', 'Map'), 'windowFunnelMap': ('windowFunnel', 'Map'), 'quantileBFloat16Map': ('quantileBFloat16', 'Map'), 'anyMap': ('any', 'Map'), 'kurtSampMap': ('kurtSamp', 'Map'), 'groupArrayMovingAvgMap': ('groupArrayMovingAvg', 'Map'), 'covarPopMap': ('covarPop', 'Map'), 'sumSimpleState': ('sum', 'SimpleState'), 'groupBitmapAndSimpleState': ('groupBitmapAnd', 'SimpleState'), 'retentionSimpleState': ('retention', 'SimpleState'), 'maxMapSimpleState': ('maxMap', 'SimpleState'), 'sumKahanSimpleState': ('sumKahan', 'SimpleState'), 'quantilesInterpolatedWeightedSimpleState': ('quantilesInterpolatedWeighted', 'SimpleState'), 'anyHeavySimpleState': ('anyHeavy', 'SimpleState'), 'sequenceMatchSimpleState': ('sequenceMatch', 'SimpleState'), 'skewPopSimpleState': ('skewPop', 'SimpleState'), 'sequenceCountSimpleState': ('sequenceCount', 'SimpleState'), 'topKSimpleState': ('topK', 'SimpleState'), 'deltaSumSimpleState': ('deltaSum', 'SimpleState'), 'quantileBFloat16WeightedSimpleState': ('quantileBFloat16Weighted', 'SimpleState'), 'uniqExactSimpleState': ('uniqExact', 'SimpleState'), 'groupBitmapOrSimpleState': ('groupBitmapOr', 'SimpleState'), 'quantilesTDigestWeightedSimpleState': ('quantilesTDigestWeighted', 'SimpleState'), 'quantileExactHighSimpleState': ('quantileExactHigh', 'SimpleState'), 'argMinSimpleState': ('argMin', 'SimpleState'), 'rankCorrSimpleState': ('rankCorr', 'SimpleState'), 'covarSampSimpleState': ('covarSamp', 'SimpleState'), 'studentTTestSimpleState': ('studentTTest', 'SimpleState'), 'meanZTestSimpleState': ('meanZTest', 'SimpleState'), 'uniqCombined64SimpleState': ('uniqCombined64', 'SimpleState'), 'medianSimpleState': ('median', 'SimpleState'), 'last_valueSimpleState': ('last_value', 'SimpleState'), 'kolmogorovSmirnovTestSimpleState': ('kolmogorovSmirnovTest', 'SimpleState'), 'groupArrayLastSimpleState': ('groupArrayLast', 'SimpleState'), 'quantilesExactHighSimpleState': ('quantilesExactHigh', 'SimpleState'), 'cramersVBiasCorrectedSimpleState': ('cramersVBiasCorrected', 'SimpleState'), 'quantileTimingWeightedSimpleState': ('quantileTimingWeighted', 'SimpleState'), 'quantileTDigestWeightedSimpleState': ('quantileTDigestWeighted', 'SimpleState'), 'sumWithOverflowSimpleState': ('sumWithOverflow', 'SimpleState'), 'quantilesGKSimpleState': ('quantilesGK', 'SimpleState'), 'quantilesDeterministicSimpleState': ('quantilesDeterministic', 'SimpleState'), 'groupBitXorSimpleState': ('groupBitXor', 'SimpleState'), 'groupArrayInsertAtSimpleState': ('groupArrayInsertAt', 'SimpleState'), 'histogramSimpleState': ('histogram', 'SimpleState'), 'uniqHLL12SimpleState': ('uniqHLL12', 'SimpleState'), 'groupArrayMovingSumSimpleState': ('groupArrayMovingSum', 'SimpleState'), 'varSampSimpleState': ('varSamp', 'SimpleState'), 'welchTTestSimpleState': ('welchTTest', 'SimpleState'), 'exponentialTimeDecayedAvgSimpleState': ('exponentialTimeDecayedAvg', 'SimpleState'), 'groupArraySimpleState': ('groupArray', 'SimpleState'), 'argMaxSimpleState': ('argMax', 'SimpleState'), 'quantileDeterministicSimpleState': ('quantileDeterministic', 'SimpleState'), 'categoricalInformationValueSimpleState': ('categoricalInformationValue', 'SimpleState'), 'deltaSumTimestampSimpleState': ('deltaSumTimestamp', 'SimpleState'), 'sumCountSimpleState': ('sumCount', 'SimpleState'), 'quantilesExactSimpleState': ('quantilesExact', 'SimpleState'), 'maxSimpleState': ('max', 'SimpleState'), 'quantilesBFloat16SimpleState': ('quantilesBFloat16', 'SimpleState'), 'sparkBarSimpleState': ('sparkBar', 'SimpleState'), 'minMapSimpleState': ('minMap', 'SimpleState'), 'simpleLinearRegressionSimpleState': ('simpleLinearRegression', 'SimpleState'), 'anyLastSimpleState': ('anyLast', 'SimpleState'), 'groupUniqArraySimpleState': ('groupUniqArray', 'SimpleState'), 'groupBitmapXorSimpleState': ('groupBitmapXor', 'SimpleState'), 'topKWeightedSimpleState': ('topKWeighted', 'SimpleState'), 'quantilesTDigestSimpleState': ('quantilesTDigest', 'SimpleState'), 'groupBitOrSimpleState': ('groupBitOr', 'SimpleState'), 'groupArraySampleSimpleState': ('groupArraySample', 'SimpleState'), 'quantileTimingSimpleState': ('quantileTiming', 'SimpleState'), 'quantilesSimpleState': ('quantiles', 'SimpleState'), 'cramersVSimpleState': ('cramersV', 'SimpleState'), 'stochasticLinearRegressionSimpleState': ('stochasticLinearRegression', 'SimpleState'), 'theilsUSimpleState': ('theilsU', 'SimpleState'), 'varPopSimpleState': ('varPop', 'SimpleState'), 'stochasticLogisticRegressionSimpleState': ('stochasticLogisticRegression', 'SimpleState'), 'sumMapSimpleState': ('sumMap', 'SimpleState'), 'quantileSimpleState': ('quantile', 'SimpleState'), 'mannWhitneyUTestSimpleState': ('mannWhitneyUTest', 'SimpleState'), 'uniqCombinedSimpleState': ('uniqCombined', 'SimpleState'), 'uniqUpToSimpleState': ('uniqUpTo', 'SimpleState'), 'contingencySimpleState': ('contingency', 'SimpleState'), 'quantilesBFloat16WeightedSimpleState': ('quantilesBFloat16Weighted', 'SimpleState'), 'uniqThetaSimpleState': ('uniqTheta', 'SimpleState'), 'quantilesExactWeightedSimpleState': ('quantilesExactWeighted', 'SimpleState'), 'uniqSimpleState': ('uniq', 'SimpleState'), 'countSimpleState': ('count', 'SimpleState'), 'quantileTDigestSimpleState': ('quantileTDigest', 'SimpleState'), 'skewSampSimpleState': ('skewSamp', 'SimpleState'), 'minSimpleState': ('min', 'SimpleState'), 'intervalLengthSumSimpleState': ('intervalLengthSum', 'SimpleState'), 'corrSimpleState': ('corr', 'SimpleState'), 'avgSimpleState': ('avg', 'SimpleState'), 'quantilesExactLowSimpleState': ('quantilesExactLow', 'SimpleState'), 'groupBitmapSimpleState': ('groupBitmap', 'SimpleState'), 'exponentialMovingAverageSimpleState': ('exponentialMovingAverage', 'SimpleState'), 'sequenceNextNodeSimpleState': ('sequenceNextNode', 'SimpleState'), 'first_valueSimpleState': ('first_value', 'SimpleState'), 'maxIntersectionsSimpleState': ('maxIntersections', 'SimpleState'), 'largestTriangleThreeBucketsSimpleState': ('largestTriangleThreeBuckets', 'SimpleState'), 'quantileExactWeightedSimpleState': ('quantileExactWeighted', 'SimpleState'), 'stddevSampSimpleState': ('stddevSamp', 'SimpleState'), 'groupBitAndSimpleState': ('groupBitAnd', 'SimpleState'), 'kurtPopSimpleState': ('kurtPop', 'SimpleState'), 'quantileGKSimpleState': ('quantileGK', 'SimpleState'), 'entropySimpleState': ('entropy', 'SimpleState'), 'stddevPopSimpleState': ('stddevPop', 'SimpleState'), 'boundingRatioSimpleState': ('boundingRatio', 'SimpleState'), 'maxIntersectionsPositionSimpleState': ('maxIntersectionsPosition', 'SimpleState'), 'quantileExactSimpleState': ('quantileExact', 'SimpleState'), 'quantilesTimingSimpleState': ('quantilesTiming', 'SimpleState'), 'avgWeightedSimpleState': ('avgWeighted', 'SimpleState'), 'quantileInterpolatedWeightedSimpleState': ('quantileInterpolatedWeighted', 'SimpleState'), 'quantilesTimingWeightedSimpleState': ('quantilesTimingWeighted', 'SimpleState'), 'quantileExactLowSimpleState': ('quantileExactLow', 'SimpleState'), 'windowFunnelSimpleState': ('windowFunnel', 'SimpleState'), 'quantileBFloat16SimpleState': ('quantileBFloat16', 'SimpleState'), 'anySimpleState': ('any', 'SimpleState'), 'kurtSampSimpleState': ('kurtSamp', 'SimpleState'), 'groupArrayMovingAvgSimpleState': ('groupArrayMovingAvg', 'SimpleState'), 'covarPopSimpleState': ('covarPop', 'SimpleState'), 'sumState': ('sum', 'State'), 'groupBitmapAndState': ('groupBitmapAnd', 'State'), 'retentionState': ('retention', 'State'), 'maxMapState': ('maxMap', 'State'), 'sumKahanState': ('sumKahan', 'State'), 'quantilesInterpolatedWeightedState': ('quantilesInterpolatedWeighted', 'State'), 'anyHeavyState': ('anyHeavy', 'State'), 'sequenceMatchState': ('sequenceMatch', 'State'), 'skewPopState': ('skewPop', 'State'), 'sequenceCountState': ('sequenceCount', 'State'), 'topKState': ('topK', 'State'), 'deltaSumState': ('deltaSum', 'State'), 'quantileBFloat16WeightedState': ('quantileBFloat16Weighted', 'State'), 'uniqExactState': ('uniqExact', 'State'), 'groupBitmapOrState': ('groupBitmapOr', 'State'), 'quantilesTDigestWeightedState': ('quantilesTDigestWeighted', 'State'), 'quantileExactHighState': ('quantileExactHigh', 'State'), 'argMinState': ('argMin', 'State'), 'rankCorrState': ('rankCorr', 'State'), 'covarSampState': ('covarSamp', 'State'), 'studentTTestState': ('studentTTest', 'State'), 'meanZTestState': ('meanZTest', 'State'), 'uniqCombined64State': ('uniqCombined64', 'State'), 'medianState': ('median', 'State'), 'last_valueState': ('last_value', 'State'), 'kolmogorovSmirnovTestState': ('kolmogorovSmirnovTest', 'State'), 'groupArrayLastState': ('groupArrayLast', 'State'), 'quantilesExactHighState': ('quantilesExactHigh', 'State'), 'cramersVBiasCorrectedState': ('cramersVBiasCorrected', 'State'), 'quantileTimingWeightedState': ('quantileTimingWeighted', 'State'), 'quantileTDigestWeightedState': ('quantileTDigestWeighted', 'State'), 'sumWithOverflowState': ('sumWithOverflow', 'State'), 'quantilesGKState': ('quantilesGK', 'State'), 'quantilesDeterministicState': ('quantilesDeterministic', 'State'), 'groupBitXorState': ('groupBitXor', 'State'), 'groupArrayInsertAtState': ('groupArrayInsertAt', 'State'), 'histogramState': ('histogram', 'State'), 'uniqHLL12State': ('uniqHLL12', 'State'), 'groupArrayMovingSumState': ('groupArrayMovingSum', 'State'), 'varSampState': ('varSamp', 'State'), 'welchTTestState': ('welchTTest', 'State'), 'exponentialTimeDecayedAvgState': ('exponentialTimeDecayedAvg', 'State'), 'groupArrayState': ('groupArray', 'State'), 'argMaxState': ('argMax', 'State'), 'quantileDeterministicState': ('quantileDeterministic', 'State'), 'categoricalInformationValueState': ('categoricalInformationValue', 'State'), 'deltaSumTimestampState': ('deltaSumTimestamp', 'State'), 'sumCountState': ('sumCount', 'State'), 'quantilesExactState': ('quantilesExact', 'State'), 'maxState': ('max', 'State'), 'quantilesBFloat16State': ('quantilesBFloat16', 'State'), 'sparkBarState': ('sparkBar', 'State'), 'minMapState': ('minMap', 'State'), 'simpleLinearRegressionState': ('simpleLinearRegression', 'State'), 'anyLastState': ('anyLast', 'State'), 'groupUniqArrayState': ('groupUniqArray', 'State'), 'groupBitmapXorState': ('groupBitmapXor', 'State'), 'topKWeightedState': ('topKWeighted', 'State'), 'quantilesTDigestState': ('quantilesTDigest', 'State'), 'groupBitOrState': ('groupBitOr', 'State'), 'groupArraySampleState': ('groupArraySample', 'State'), 'quantileTimingState': ('quantileTiming', 'State'), 'quantilesState': ('quantiles', 'State'), 'cramersVState': ('cramersV', 'State'), 'stochasticLinearRegressionState': ('stochasticLinearRegression', 'State'), 'theilsUState': ('theilsU', 'State'), 'varPopState': ('varPop', 'State'), 'stochasticLogisticRegressionState': ('stochasticLogisticRegression', 'State'), 'sumMapState': ('sumMap', 'State'), 'quantileState': ('quantile', 'State'), 'mannWhitneyUTestState': ('mannWhitneyUTest', 'State'), 'uniqCombinedState': ('uniqCombined', 'State'), 'uniqUpToState': ('uniqUpTo', 'State'), 'contingencyState': ('contingency', 'State'), 'quantilesBFloat16WeightedState': ('quantilesBFloat16Weighted', 'State'), 'uniqThetaState': ('uniqTheta', 'State'), 'quantilesExactWeightedState': ('quantilesExactWeighted', 'State'), 'uniqState': ('uniq', 'State'), 'countState': ('count', 'State'), 'quantileTDigestState': ('quantileTDigest', 'State'), 'skewSampState': ('skewSamp', 'State'), 'minState': ('min', 'State'), 'intervalLengthSumState': ('intervalLengthSum', 'State'), 'corrState': ('corr', 'State'), 'avgState': ('avg', 'State'), 'quantilesExactLowState': ('quantilesExactLow', 'State'), 'groupBitmapState': ('groupBitmap', 'State'), 'exponentialMovingAverageState': ('exponentialMovingAverage', 'State'), 'sequenceNextNodeState': ('sequenceNextNode', 'State'), 'first_valueState': ('first_value', 'State'), 'maxIntersectionsState': ('maxIntersections', 'State'), 'largestTriangleThreeBucketsState': ('largestTriangleThreeBuckets', 'State'), 'quantileExactWeightedState': ('quantileExactWeighted', 'State'), 'stddevSampState': ('stddevSamp', 'State'), 'groupBitAndState': ('groupBitAnd', 'State'), 'kurtPopState': ('kurtPop', 'State'), 'quantileGKState': ('quantileGK', 'State'), 'entropyState': ('entropy', 'State'), 'stddevPopState': ('stddevPop', 'State'), 'boundingRatioState': ('boundingRatio', 'State'), 'maxIntersectionsPositionState': ('maxIntersectionsPosition', 'State'), 'quantileExactState': ('quantileExact', 'State'), 'quantilesTimingState': ('quantilesTiming', 'State'), 'avgWeightedState': ('avgWeighted', 'State'), 'quantileInterpolatedWeightedState': ('quantileInterpolatedWeighted', 'State'), 'quantilesTimingWeightedState': ('quantilesTimingWeighted', 'State'), 'quantileExactLowState': ('quantileExactLow', 'State'), 'windowFunnelState': ('windowFunnel', 'State'), 'quantileBFloat16State': ('quantileBFloat16', 'State'), 'anyState': ('any', 'State'), 'kurtSampState': ('kurtSamp', 'State'), 'groupArrayMovingAvgState': ('groupArrayMovingAvg', 'State'), 'covarPopState': ('covarPop', 'State'), 'sumMerge': ('sum', 'Merge'), 'groupBitmapAndMerge': ('groupBitmapAnd', 'Merge'), 'retentionMerge': ('retention', 'Merge'), 'maxMapMerge': ('maxMap', 'Merge'), 'sumKahanMerge': ('sumKahan', 'Merge'), 'quantilesInterpolatedWeightedMerge': ('quantilesInterpolatedWeighted', 'Merge'), 'anyHeavyMerge': ('anyHeavy', 'Merge'), 'sequenceMatchMerge': ('sequenceMatch', 'Merge'), 'skewPopMerge': ('skewPop', 'Merge'), 'sequenceCountMerge': ('sequenceCount', 'Merge'), 'topKMerge': ('topK', 'Merge'), 'deltaSumMerge': ('deltaSum', 'Merge'), 'quantileBFloat16WeightedMerge': ('quantileBFloat16Weighted', 'Merge'), 'uniqExactMerge': ('uniqExact', 'Merge'), 'groupBitmapOrMerge': ('groupBitmapOr', 'Merge'), 'quantilesTDigestWeightedMerge': ('quantilesTDigestWeighted', 'Merge'), 'quantileExactHighMerge': ('quantileExactHigh', 'Merge'), 'argMinMerge': ('argMin', 'Merge'), 'rankCorrMerge': ('rankCorr', 'Merge'), 'covarSampMerge': ('covarSamp', 'Merge'), 'studentTTestMerge': ('studentTTest', 'Merge'), 'meanZTestMerge': ('meanZTest', 'Merge'), 'uniqCombined64Merge': ('uniqCombined64', 'Merge'), 'medianMerge': ('median', 'Merge'), 'last_valueMerge': ('last_value', 'Merge'), 'kolmogorovSmirnovTestMerge': ('kolmogorovSmirnovTest', 'Merge'), 'groupArrayLastMerge': ('groupArrayLast', 'Merge'), 'quantilesExactHighMerge': ('quantilesExactHigh', 'Merge'), 'cramersVBiasCorrectedMerge': ('cramersVBiasCorrected', 'Merge'), 'quantileTimingWeightedMerge': ('quantileTimingWeighted', 'Merge'), 'quantileTDigestWeightedMerge': ('quantileTDigestWeighted', 'Merge'), 'sumWithOverflowMerge': ('sumWithOverflow', 'Merge'), 'quantilesGKMerge': ('quantilesGK', 'Merge'), 'quantilesDeterministicMerge': ('quantilesDeterministic', 'Merge'), 'groupBitXorMerge': ('groupBitXor', 'Merge'), 'groupArrayInsertAtMerge': ('groupArrayInsertAt', 'Merge'), 'histogramMerge': ('histogram', 'Merge'), 'uniqHLL12Merge': ('uniqHLL12', 'Merge'), 'groupArrayMovingSumMerge': ('groupArrayMovingSum', 'Merge'), 'varSampMerge': ('varSamp', 'Merge'), 'welchTTestMerge': ('welchTTest', 'Merge'), 'exponentialTimeDecayedAvgMerge': ('exponentialTimeDecayedAvg', 'Merge'), 'groupArrayMerge': ('groupArray', 'Merge'), 'argMaxMerge': ('argMax', 'Merge'), 'quantileDeterministicMerge': ('quantileDeterministic', 'Merge'), 'categoricalInformationValueMerge': ('categoricalInformationValue', 'Merge'), 'deltaSumTimestampMerge': ('deltaSumTimestamp', 'Merge'), 'sumCountMerge': ('sumCount', 'Merge'), 'quantilesExactMerge': ('quantilesExact', 'Merge'), 'maxMerge': ('max', 'Merge'), 'quantilesBFloat16Merge': ('quantilesBFloat16', 'Merge'), 'sparkBarMerge': ('sparkBar', 'Merge'), 'minMapMerge': ('minMap', 'Merge'), 'simpleLinearRegressionMerge': ('simpleLinearRegression', 'Merge'), 'anyLastMerge': ('anyLast', 'Merge'), 'groupUniqArrayMerge': ('groupUniqArray', 'Merge'), 'groupBitmapXorMerge': ('groupBitmapXor', 'Merge'), 'topKWeightedMerge': ('topKWeighted', 'Merge'), 'quantilesTDigestMerge': ('quantilesTDigest', 'Merge'), 'groupBitOrMerge': ('groupBitOr', 'Merge'), 'groupArraySampleMerge': ('groupArraySample', 'Merge'), 'quantileTimingMerge': ('quantileTiming', 'Merge'), 'quantilesMerge': ('quantiles', 'Merge'), 'cramersVMerge': ('cramersV', 'Merge'), 'stochasticLinearRegressionMerge': ('stochasticLinearRegression', 'Merge'), 'theilsUMerge': ('theilsU', 'Merge'), 'varPopMerge': ('varPop', 'Merge'), 'stochasticLogisticRegressionMerge': ('stochasticLogisticRegression', 'Merge'), 'sumMapMerge': ('sumMap', 'Merge'), 'quantileMerge': ('quantile', 'Merge'), 'mannWhitneyUTestMerge': ('mannWhitneyUTest', 'Merge'), 'uniqCombinedMerge': ('uniqCombined', 'Merge'), 'uniqUpToMerge': ('uniqUpTo', 'Merge'), 'contingencyMerge': ('contingency', 'Merge'), 'quantilesBFloat16WeightedMerge': ('quantilesBFloat16Weighted', 'Merge'), 'uniqThetaMerge': ('uniqTheta', 'Merge'), 'quantilesExactWeightedMerge': ('quantilesExactWeighted', 'Merge'), 'uniqMerge': ('uniq', 'Merge'), 'countMerge': ('count', 'Merge'), 'quantileTDigestMerge': ('quantileTDigest', 'Merge'), 'skewSampMerge': ('skewSamp', 'Merge'), 'minMerge': ('min', 'Merge'), 'intervalLengthSumMerge': ('intervalLengthSum', 'Merge'), 'corrMerge': ('corr', 'Merge'), 'avgMerge': ('avg', 'Merge'), 'quantilesExactLowMerge': ('quantilesExactLow', 'Merge'), 'groupBitmapMerge': ('groupBitmap', 'Merge'), 'exponentialMovingAverageMerge': ('exponentialMovingAverage', 'Merge'), 'sequenceNextNodeMerge': ('sequenceNextNode', 'Merge'), 'first_valueMerge': ('first_value', 'Merge'), 'maxIntersectionsMerge': ('maxIntersections', 'Merge'), 'largestTriangleThreeBucketsMerge': ('largestTriangleThreeBuckets', 'Merge'), 'quantileExactWeightedMerge': ('quantileExactWeighted', 'Merge'), 'stddevSampMerge': ('stddevSamp', 'Merge'), 'groupBitAndMerge': ('groupBitAnd', 'Merge'), 'kurtPopMerge': ('kurtPop', 'Merge'), 'quantileGKMerge': ('quantileGK', 'Merge'), 'entropyMerge': ('entropy', 'Merge'), 'stddevPopMerge': ('stddevPop', 'Merge'), 'boundingRatioMerge': ('boundingRatio', 'Merge'), 'maxIntersectionsPositionMerge': ('maxIntersectionsPosition', 'Merge'), 'quantileExactMerge': ('quantileExact', 'Merge'), 'quantilesTimingMerge': ('quantilesTiming', 'Merge'), 'avgWeightedMerge': ('avgWeighted', 'Merge'), 'quantileInterpolatedWeightedMerge': ('quantileInterpolatedWeighted', 'Merge'), 'quantilesTimingWeightedMerge': ('quantilesTimingWeighted', 'Merge'), 'quantileExactLowMerge': ('quantileExactLow', 'Merge'), 'windowFunnelMerge': ('windowFunnel', 'Merge'), 'quantileBFloat16Merge': ('quantileBFloat16', 'Merge'), 'anyMerge': ('any', 'Merge'), 'kurtSampMerge': ('kurtSamp', 'Merge'), 'groupArrayMovingAvgMerge': ('groupArrayMovingAvg', 'Merge'), 'covarPopMerge': ('covarPop', 'Merge'), 'sumMergeState': ('sum', 'MergeState'), 'groupBitmapAndMergeState': ('groupBitmapAnd', 'MergeState'), 'retentionMergeState': ('retention', 'MergeState'), 'maxMapMergeState': ('maxMap', 'MergeState'), 'sumKahanMergeState': ('sumKahan', 'MergeState'), 'quantilesInterpolatedWeightedMergeState': ('quantilesInterpolatedWeighted', 'MergeState'), 'anyHeavyMergeState': ('anyHeavy', 'MergeState'), 'sequenceMatchMergeState': ('sequenceMatch', 'MergeState'), 'skewPopMergeState': ('skewPop', 'MergeState'), 'sequenceCountMergeState': ('sequenceCount', 'MergeState'), 'topKMergeState': ('topK', 'MergeState'), 'deltaSumMergeState': ('deltaSum', 'MergeState'), 'quantileBFloat16WeightedMergeState': ('quantileBFloat16Weighted', 'MergeState'), 'uniqExactMergeState': ('uniqExact', 'MergeState'), 'groupBitmapOrMergeState': ('groupBitmapOr', 'MergeState'), 'quantilesTDigestWeightedMergeState': ('quantilesTDigestWeighted', 'MergeState'), 'quantileExactHighMergeState': ('quantileExactHigh', 'MergeState'), 'argMinMergeState': ('argMin', 'MergeState'), 'rankCorrMergeState': ('rankCorr', 'MergeState'), 'covarSampMergeState': ('covarSamp', 'MergeState'), 'studentTTestMergeState': ('studentTTest', 'MergeState'), 'meanZTestMergeState': ('meanZTest', 'MergeState'), 'uniqCombined64MergeState': ('uniqCombined64', 'MergeState'), 'medianMergeState': ('median', 'MergeState'), 'last_valueMergeState': ('last_value', 'MergeState'), 'kolmogorovSmirnovTestMergeState': ('kolmogorovSmirnovTest', 'MergeState'), 'groupArrayLastMergeState': ('groupArrayLast', 'MergeState'), 'quantilesExactHighMergeState': ('quantilesExactHigh', 'MergeState'), 'cramersVBiasCorrectedMergeState': ('cramersVBiasCorrected', 'MergeState'), 'quantileTimingWeightedMergeState': ('quantileTimingWeighted', 'MergeState'), 'quantileTDigestWeightedMergeState': ('quantileTDigestWeighted', 'MergeState'), 'sumWithOverflowMergeState': ('sumWithOverflow', 'MergeState'), 'quantilesGKMergeState': ('quantilesGK', 'MergeState'), 'quantilesDeterministicMergeState': ('quantilesDeterministic', 'MergeState'), 'groupBitXorMergeState': ('groupBitXor', 'MergeState'), 'groupArrayInsertAtMergeState': ('groupArrayInsertAt', 'MergeState'), 'histogramMergeState': ('histogram', 'MergeState'), 'uniqHLL12MergeState': ('uniqHLL12', 'MergeState'), 'groupArrayMovingSumMergeState': ('groupArrayMovingSum', 'MergeState'), 'varSampMergeState': ('varSamp', 'MergeState'), 'welchTTestMergeState': ('welchTTest', 'MergeState'), 'exponentialTimeDecayedAvgMergeState': ('exponentialTimeDecayedAvg', 'MergeState'), 'groupArrayMergeState': ('groupArray', 'MergeState'), 'argMaxMergeState': ('argMax', 'MergeState'), 'quantileDeterministicMergeState': ('quantileDeterministic', 'MergeState'), 'categoricalInformationValueMergeState': ('categoricalInformationValue', 'MergeState'), 'deltaSumTimestampMergeState': ('deltaSumTimestamp', 'MergeState'), 'sumCountMergeState': ('sumCount', 'MergeState'), 'quantilesExactMergeState': ('quantilesExact', 'MergeState'), 'maxMergeState': ('max', 'MergeState'), 'quantilesBFloat16MergeState': ('quantilesBFloat16', 'MergeState'), 'sparkBarMergeState': ('sparkBar', 'MergeState'), 'minMapMergeState': ('minMap', 'MergeState'), 'simpleLinearRegressionMergeState': ('simpleLinearRegression', 'MergeState'), 'anyLastMergeState': ('anyLast', 'MergeState'), 'groupUniqArrayMergeState': ('groupUniqArray', 'MergeState'), 'groupBitmapXorMergeState': ('groupBitmapXor', 'MergeState'), 'topKWeightedMergeState': ('topKWeighted', 'MergeState'), 'quantilesTDigestMergeState': ('quantilesTDigest', 'MergeState'), 'groupBitOrMergeState': ('groupBitOr', 'MergeState'), 'groupArraySampleMergeState': ('groupArraySample', 'MergeState'), 'quantileTimingMergeState': ('quantileTiming', 'MergeState'), 'quantilesMergeState': ('quantiles', 'MergeState'), 'cramersVMergeState': ('cramersV', 'MergeState'), 'stochasticLinearRegressionMergeState': ('stochasticLinearRegression', 'MergeState'), 'theilsUMergeState': ('theilsU', 'MergeState'), 'varPopMergeState': ('varPop', 'MergeState'), 'stochasticLogisticRegressionMergeState': ('stochasticLogisticRegression', 'MergeState'), 'sumMapMergeState': ('sumMap', 'MergeState'), 'quantileMergeState': ('quantile', 'MergeState'), 'mannWhitneyUTestMergeState': ('mannWhitneyUTest', 'MergeState'), 'uniqCombinedMergeState': ('uniqCombined', 'MergeState'), 'uniqUpToMergeState': ('uniqUpTo', 'MergeState'), 'contingencyMergeState': ('contingency', 'MergeState'), 'quantilesBFloat16WeightedMergeState': ('quantilesBFloat16Weighted', 'MergeState'), 'uniqThetaMergeState': ('uniqTheta', 'MergeState'), 'quantilesExactWeightedMergeState': ('quantilesExactWeighted', 'MergeState'), 'uniqMergeState': ('uniq', 'MergeState'), 'countMergeState': ('count', 'MergeState'), 'quantileTDigestMergeState': ('quantileTDigest', 'MergeState'), 'skewSampMergeState': ('skewSamp', 'MergeState'), 'minMergeState': ('min', 'MergeState'), 'intervalLengthSumMergeState': ('intervalLengthSum', 'MergeState'), 'corrMergeState': ('corr', 'MergeState'), 'avgMergeState': ('avg', 'MergeState'), 'quantilesExactLowMergeState': ('quantilesExactLow', 'MergeState'), 'groupBitmapMergeState': ('groupBitmap', 'MergeState'), 'exponentialMovingAverageMergeState': ('exponentialMovingAverage', 'MergeState'), 'sequenceNextNodeMergeState': ('sequenceNextNode', 'MergeState'), 'first_valueMergeState': ('first_value', 'MergeState'), 'maxIntersectionsMergeState': ('maxIntersections', 'MergeState'), 'largestTriangleThreeBucketsMergeState': ('largestTriangleThreeBuckets', 'MergeState'), 'quantileExactWeightedMergeState': ('quantileExactWeighted', 'MergeState'), 'stddevSampMergeState': ('stddevSamp', 'MergeState'), 'groupBitAndMergeState': ('groupBitAnd', 'MergeState'), 'kurtPopMergeState': ('kurtPop', 'MergeState'), 'quantileGKMergeState': ('quantileGK', 'MergeState'), 'entropyMergeState': ('entropy', 'MergeState'), 'stddevPopMergeState': ('stddevPop', 'MergeState'), 'boundingRatioMergeState': ('boundingRatio', 'MergeState'), 'maxIntersectionsPositionMergeState': ('maxIntersectionsPosition', 'MergeState'), 'quantileExactMergeState': ('quantileExact', 'MergeState'), 'quantilesTimingMergeState': ('quantilesTiming', 'MergeState'), 'avgWeightedMergeState': ('avgWeighted', 'MergeState'), 'quantileInterpolatedWeightedMergeState': ('quantileInterpolatedWeighted', 'MergeState'), 'quantilesTimingWeightedMergeState': ('quantilesTimingWeighted', 'MergeState'), 'quantileExactLowMergeState': ('quantileExactLow', 'MergeState'), 'windowFunnelMergeState': ('windowFunnel', 'MergeState'), 'quantileBFloat16MergeState': ('quantileBFloat16', 'MergeState'), 'anyMergeState': ('any', 'MergeState'), 'kurtSampMergeState': ('kurtSamp', 'MergeState'), 'groupArrayMovingAvgMergeState': ('groupArrayMovingAvg', 'MergeState'), 'covarPopMergeState': ('covarPop', 'MergeState'), 'sumForEach': ('sum', 'ForEach'), 'groupBitmapAndForEach': ('groupBitmapAnd', 'ForEach'), 'retentionForEach': ('retention', 'ForEach'), 'maxMapForEach': ('maxMap', 'ForEach'), 'sumKahanForEach': ('sumKahan', 'ForEach'), 'quantilesInterpolatedWeightedForEach': ('quantilesInterpolatedWeighted', 'ForEach'), 'anyHeavyForEach': ('anyHeavy', 'ForEach'), 'sequenceMatchForEach': ('sequenceMatch', 'ForEach'), 'skewPopForEach': ('skewPop', 'ForEach'), 'sequenceCountForEach': ('sequenceCount', 'ForEach'), 'topKForEach': ('topK', 'ForEach'), 'deltaSumForEach': ('deltaSum', 'ForEach'), 'quantileBFloat16WeightedForEach': ('quantileBFloat16Weighted', 'ForEach'), 'uniqExactForEach': ('uniqExact', 'ForEach'), 'groupBitmapOrForEach': ('groupBitmapOr', 'ForEach'), 'quantilesTDigestWeightedForEach': ('quantilesTDigestWeighted', 'ForEach'), 'quantileExactHighForEach': ('quantileExactHigh', 'ForEach'), 'argMinForEach': ('argMin', 'ForEach'), 'rankCorrForEach': ('rankCorr', 'ForEach'), 'covarSampForEach': ('covarSamp', 'ForEach'), 'studentTTestForEach': ('studentTTest', 'ForEach'), 'meanZTestForEach': ('meanZTest', 'ForEach'), 'uniqCombined64ForEach': ('uniqCombined64', 'ForEach'), 'medianForEach': ('median', 'ForEach'), 'last_valueForEach': ('last_value', 'ForEach'), 'kolmogorovSmirnovTestForEach': ('kolmogorovSmirnovTest', 'ForEach'), 'groupArrayLastForEach': ('groupArrayLast', 'ForEach'), 'quantilesExactHighForEach': ('quantilesExactHigh', 'ForEach'), 'cramersVBiasCorrectedForEach': ('cramersVBiasCorrected', 'ForEach'), 'quantileTimingWeightedForEach': ('quantileTimingWeighted', 'ForEach'), 'quantileTDigestWeightedForEach': ('quantileTDigestWeighted', 'ForEach'), 'sumWithOverflowForEach': ('sumWithOverflow', 'ForEach'), 'quantilesGKForEach': ('quantilesGK', 'ForEach'), 'quantilesDeterministicForEach': ('quantilesDeterministic', 'ForEach'), 'groupBitXorForEach': ('groupBitXor', 'ForEach'), 'groupArrayInsertAtForEach': ('groupArrayInsertAt', 'ForEach'), 'histogramForEach': ('histogram', 'ForEach'), 'uniqHLL12ForEach': ('uniqHLL12', 'ForEach'), 'groupArrayMovingSumForEach': ('groupArrayMovingSum', 'ForEach'), 'varSampForEach': ('varSamp', 'ForEach'), 'welchTTestForEach': ('welchTTest', 'ForEach'), 'exponentialTimeDecayedAvgForEach': ('exponentialTimeDecayedAvg', 'ForEach'), 'groupArrayForEach': ('groupArray', 'ForEach'), 'argMaxForEach': ('argMax', 'ForEach'), 'quantileDeterministicForEach': ('quantileDeterministic', 'ForEach'), 'categoricalInformationValueForEach': ('categoricalInformationValue', 'ForEach'), 'deltaSumTimestampForEach': ('deltaSumTimestamp', 'ForEach'), 'sumCountForEach': ('sumCount', 'ForEach'), 'quantilesExactForEach': ('quantilesExact', 'ForEach'), 'maxForEach': ('max', 'ForEach'), 'quantilesBFloat16ForEach': ('quantilesBFloat16', 'ForEach'), 'sparkBarForEach': ('sparkBar', 'ForEach'), 'minMapForEach': ('minMap', 'ForEach'), 'simpleLinearRegressionForEach': ('simpleLinearRegression', 'ForEach'), 'anyLastForEach': ('anyLast', 'ForEach'), 'groupUniqArrayForEach': ('groupUniqArray', 'ForEach'), 'groupBitmapXorForEach': ('groupBitmapXor', 'ForEach'), 'topKWeightedForEach': ('topKWeighted', 'ForEach'), 'quantilesTDigestForEach': ('quantilesTDigest', 'ForEach'), 'groupBitOrForEach': ('groupBitOr', 'ForEach'), 'groupArraySampleForEach': ('groupArraySample', 'ForEach'), 'quantileTimingForEach': ('quantileTiming', 'ForEach'), 'quantilesForEach': ('quantiles', 'ForEach'), 'cramersVForEach': ('cramersV', 'ForEach'), 'stochasticLinearRegressionForEach': ('stochasticLinearRegression', 'ForEach'), 'theilsUForEach': ('theilsU', 'ForEach'), 'varPopForEach': ('varPop', 'ForEach'), 'stochasticLogisticRegressionForEach': ('stochasticLogisticRegression', 'ForEach'), 'sumMapForEach': ('sumMap', 'ForEach'), 'quantileForEach': ('quantile', 'ForEach'), 'mannWhitneyUTestForEach': ('mannWhitneyUTest', 'ForEach'), 'uniqCombinedForEach': ('uniqCombined', 'ForEach'), 'uniqUpToForEach': ('uniqUpTo', 'ForEach'), 'contingencyForEach': ('contingency', 'ForEach'), 'quantilesBFloat16WeightedForEach': ('quantilesBFloat16Weighted', 'ForEach'), 'uniqThetaForEach': ('uniqTheta', 'ForEach'), 'quantilesExactWeightedForEach': ('quantilesExactWeighted', 'ForEach'), 'uniqForEach': ('uniq', 'ForEach'), 'countForEach': ('count', 'ForEach'), 'quantileTDigestForEach': ('quantileTDigest', 'ForEach'), 'skewSampForEach': ('skewSamp', 'ForEach'), 'minForEach': ('min', 'ForEach'), 'intervalLengthSumForEach': ('intervalLengthSum', 'ForEach'), 'corrForEach': ('corr', 'ForEach'), 'avgForEach': ('avg', 'ForEach'), 'quantilesExactLowForEach': ('quantilesExactLow', 'ForEach'), 'groupBitmapForEach': ('groupBitmap', 'ForEach'), 'exponentialMovingAverageForEach': ('exponentialMovingAverage', 'ForEach'), 'sequenceNextNodeForEach': ('sequenceNextNode', 'ForEach'), 'first_valueForEach': ('first_value', 'ForEach'), 'maxIntersectionsForEach': ('maxIntersections', 'ForEach'), 'largestTriangleThreeBucketsForEach': ('largestTriangleThreeBuckets', 'ForEach'), 'quantileExactWeightedForEach': ('quantileExactWeighted', 'ForEach'), 'stddevSampForEach': ('stddevSamp', 'ForEach'), 'groupBitAndForEach': ('groupBitAnd', 'ForEach'), 'kurtPopForEach': ('kurtPop', 'ForEach'), 'quantileGKForEach': ('quantileGK', 'ForEach'), 'entropyForEach': ('entropy', 'ForEach'), 'stddevPopForEach': ('stddevPop', 'ForEach'), 'boundingRatioForEach': ('boundingRatio', 'ForEach'), 'maxIntersectionsPositionForEach': ('maxIntersectionsPosition', 'ForEach'), 'quantileExactForEach': ('quantileExact', 'ForEach'), 'quantilesTimingForEach': ('quantilesTiming', 'ForEach'), 'avgWeightedForEach': ('avgWeighted', 'ForEach'), 'quantileInterpolatedWeightedForEach': ('quantileInterpolatedWeighted', 'ForEach'), 'quantilesTimingWeightedForEach': ('quantilesTimingWeighted', 'ForEach'), 'quantileExactLowForEach': ('quantileExactLow', 'ForEach'), 'windowFunnelForEach': ('windowFunnel', 'ForEach'), 'quantileBFloat16ForEach': ('quantileBFloat16', 'ForEach'), 'anyForEach': ('any', 'ForEach'), 'kurtSampForEach': ('kurtSamp', 'ForEach'), 'groupArrayMovingAvgForEach': ('groupArrayMovingAvg', 'ForEach'), 'covarPopForEach': ('covarPop', 'ForEach'), 'sumDistinct': ('sum', 'Distinct'), 'groupBitmapAndDistinct': ('groupBitmapAnd', 'Distinct'), 'retentionDistinct': ('retention', 'Distinct'), 'maxMapDistinct': ('maxMap', 'Distinct'), 'sumKahanDistinct': ('sumKahan', 'Distinct'), 'quantilesInterpolatedWeightedDistinct': ('quantilesInterpolatedWeighted', 'Distinct'), 'anyHeavyDistinct': ('anyHeavy', 'Distinct'), 'sequenceMatchDistinct': ('sequenceMatch', 'Distinct'), 'skewPopDistinct': ('skewPop', 'Distinct'), 'sequenceCountDistinct': ('sequenceCount', 'Distinct'), 'topKDistinct': ('topK', 'Distinct'), 'deltaSumDistinct': ('deltaSum', 'Distinct'), 'quantileBFloat16WeightedDistinct': ('quantileBFloat16Weighted', 'Distinct'), 'uniqExactDistinct': ('uniqExact', 'Distinct'), 'groupBitmapOrDistinct': ('groupBitmapOr', 'Distinct'), 'quantilesTDigestWeightedDistinct': ('quantilesTDigestWeighted', 'Distinct'), 'quantileExactHighDistinct': ('quantileExactHigh', 'Distinct'), 'argMinDistinct': ('argMin', 'Distinct'), 'rankCorrDistinct': ('rankCorr', 'Distinct'), 'covarSampDistinct': ('covarSamp', 'Distinct'), 'studentTTestDistinct': ('studentTTest', 'Distinct'), 'meanZTestDistinct': ('meanZTest', 'Distinct'), 'uniqCombined64Distinct': ('uniqCombined64', 'Distinct'), 'medianDistinct': ('median', 'Distinct'), 'last_valueDistinct': ('last_value', 'Distinct'), 'kolmogorovSmirnovTestDistinct': ('kolmogorovSmirnovTest', 'Distinct'), 'groupArrayLastDistinct': ('groupArrayLast', 'Distinct'), 'quantilesExactHighDistinct': ('quantilesExactHigh', 'Distinct'), 'cramersVBiasCorrectedDistinct': ('cramersVBiasCorrected', 'Distinct'), 'quantileTimingWeightedDistinct': ('quantileTimingWeighted', 'Distinct'), 'quantileTDigestWeightedDistinct': ('quantileTDigestWeighted', 'Distinct'), 'sumWithOverflowDistinct': ('sumWithOverflow', 'Distinct'), 'quantilesGKDistinct': ('quantilesGK', 'Distinct'), 'quantilesDeterministicDistinct': ('quantilesDeterministic', 'Distinct'), 'groupBitXorDistinct': ('groupBitXor', 'Distinct'), 'groupArrayInsertAtDistinct': ('groupArrayInsertAt', 'Distinct'), 'histogramDistinct': ('histogram', 'Distinct'), 'uniqHLL12Distinct': ('uniqHLL12', 'Distinct'), 'groupArrayMovingSumDistinct': ('groupArrayMovingSum', 'Distinct'), 'varSampDistinct': ('varSamp', 'Distinct'), 'welchTTestDistinct': ('welchTTest', 'Distinct'), 'exponentialTimeDecayedAvgDistinct': ('exponentialTimeDecayedAvg', 'Distinct'), 'groupArrayDistinct': ('groupArray', 'Distinct'), 'argMaxDistinct': ('argMax', 'Distinct'), 'quantileDeterministicDistinct': ('quantileDeterministic', 'Distinct'), 'categoricalInformationValueDistinct': ('categoricalInformationValue', 'Distinct'), 'deltaSumTimestampDistinct': ('deltaSumTimestamp', 'Distinct'), 'sumCountDistinct': ('sumCount', 'Distinct'), 'quantilesExactDistinct': ('quantilesExact', 'Distinct'), 'maxDistinct': ('max', 'Distinct'), 'quantilesBFloat16Distinct': ('quantilesBFloat16', 'Distinct'), 'sparkBarDistinct': ('sparkBar', 'Distinct'), 'minMapDistinct': ('minMap', 'Distinct'), 'simpleLinearRegressionDistinct': ('simpleLinearRegression', 'Distinct'), 'anyLastDistinct': ('anyLast', 'Distinct'), 'groupUniqArrayDistinct': ('groupUniqArray', 'Distinct'), 'groupBitmapXorDistinct': ('groupBitmapXor', 'Distinct'), 'topKWeightedDistinct': ('topKWeighted', 'Distinct'), 'quantilesTDigestDistinct': ('quantilesTDigest', 'Distinct'), 'groupBitOrDistinct': ('groupBitOr', 'Distinct'), 'groupArraySampleDistinct': ('groupArraySample', 'Distinct'), 'quantileTimingDistinct': ('quantileTiming', 'Distinct'), 'quantilesDistinct': ('quantiles', 'Distinct'), 'cramersVDistinct': ('cramersV', 'Distinct'), 'stochasticLinearRegressionDistinct': ('stochasticLinearRegression', 'Distinct'), 'theilsUDistinct': ('theilsU', 'Distinct'), 'varPopDistinct': ('varPop', 'Distinct'), 'stochasticLogisticRegressionDistinct': ('stochasticLogisticRegression', 'Distinct'), 'sumMapDistinct': ('sumMap', 'Distinct'), 'quantileDistinct': ('quantile', 'Distinct'), 'mannWhitneyUTestDistinct': ('mannWhitneyUTest', 'Distinct'), 'uniqCombinedDistinct': ('uniqCombined', 'Distinct'), 'uniqUpToDistinct': ('uniqUpTo', 'Distinct'), 'contingencyDistinct': ('contingency', 'Distinct'), 'quantilesBFloat16WeightedDistinct': ('quantilesBFloat16Weighted', 'Distinct'), 'uniqThetaDistinct': ('uniqTheta', 'Distinct'), 'quantilesExactWeightedDistinct': ('quantilesExactWeighted', 'Distinct'), 'uniqDistinct': ('uniq', 'Distinct'), 'countDistinct': ('count', 'Distinct'), 'quantileTDigestDistinct': ('quantileTDigest', 'Distinct'), 'skewSampDistinct': ('skewSamp', 'Distinct'), 'minDistinct': ('min', 'Distinct'), 'intervalLengthSumDistinct': ('intervalLengthSum', 'Distinct'), 'corrDistinct': ('corr', 'Distinct'), 'avgDistinct': ('avg', 'Distinct'), 'quantilesExactLowDistinct': ('quantilesExactLow', 'Distinct'), 'groupBitmapDistinct': ('groupBitmap', 'Distinct'), 'exponentialMovingAverageDistinct': ('exponentialMovingAverage', 'Distinct'), 'sequenceNextNodeDistinct': ('sequenceNextNode', 'Distinct'), 'first_valueDistinct': ('first_value', 'Distinct'), 'maxIntersectionsDistinct': ('maxIntersections', 'Distinct'), 'largestTriangleThreeBucketsDistinct': ('largestTriangleThreeBuckets', 'Distinct'), 'quantileExactWeightedDistinct': ('quantileExactWeighted', 'Distinct'), 'stddevSampDistinct': ('stddevSamp', 'Distinct'), 'groupBitAndDistinct': ('groupBitAnd', 'Distinct'), 'kurtPopDistinct': ('kurtPop', 'Distinct'), 'quantileGKDistinct': ('quantileGK', 'Distinct'), 'entropyDistinct': ('entropy', 'Distinct'), 'stddevPopDistinct': ('stddevPop', 'Distinct'), 'boundingRatioDistinct': ('boundingRatio', 'Distinct'), 'maxIntersectionsPositionDistinct': ('maxIntersectionsPosition', 'Distinct'), 'quantileExactDistinct': ('quantileExact', 'Distinct'), 'quantilesTimingDistinct': ('quantilesTiming', 'Distinct'), 'avgWeightedDistinct': ('avgWeighted', 'Distinct'), 'quantileInterpolatedWeightedDistinct': ('quantileInterpolatedWeighted', 'Distinct'), 'quantilesTimingWeightedDistinct': ('quantilesTimingWeighted', 'Distinct'), 'quantileExactLowDistinct': ('quantileExactLow', 'Distinct'), 'windowFunnelDistinct': ('windowFunnel', 'Distinct'), 'quantileBFloat16Distinct': ('quantileBFloat16', 'Distinct'), 'anyDistinct': ('any', 'Distinct'), 'kurtSampDistinct': ('kurtSamp', 'Distinct'), 'groupArrayMovingAvgDistinct': ('groupArrayMovingAvg', 'Distinct'), 'covarPopDistinct': ('covarPop', 'Distinct'), 'sumOrDefault': ('sum', 'OrDefault'), 'groupBitmapAndOrDefault': ('groupBitmapAnd', 'OrDefault'), 'retentionOrDefault': ('retention', 'OrDefault'), 'maxMapOrDefault': ('maxMap', 'OrDefault'), 'sumKahanOrDefault': ('sumKahan', 'OrDefault'), 'quantilesInterpolatedWeightedOrDefault': ('quantilesInterpolatedWeighted', 'OrDefault'), 'anyHeavyOrDefault': ('anyHeavy', 'OrDefault'), 'sequenceMatchOrDefault': ('sequenceMatch', 'OrDefault'), 'skewPopOrDefault': ('skewPop', 'OrDefault'), 'sequenceCountOrDefault': ('sequenceCount', 'OrDefault'), 'topKOrDefault': ('topK', 'OrDefault'), 'deltaSumOrDefault': ('deltaSum', 'OrDefault'), 'quantileBFloat16WeightedOrDefault': ('quantileBFloat16Weighted', 'OrDefault'), 'uniqExactOrDefault': ('uniqExact', 'OrDefault'), 'groupBitmapOrOrDefault': ('groupBitmapOr', 'OrDefault'), 'quantilesTDigestWeightedOrDefault': ('quantilesTDigestWeighted', 'OrDefault'), 'quantileExactHighOrDefault': ('quantileExactHigh', 'OrDefault'), 'argMinOrDefault': ('argMin', 'OrDefault'), 'rankCorrOrDefault': ('rankCorr', 'OrDefault'), 'covarSampOrDefault': ('covarSamp', 'OrDefault'), 'studentTTestOrDefault': ('studentTTest', 'OrDefault'), 'meanZTestOrDefault': ('meanZTest', 'OrDefault'), 'uniqCombined64OrDefault': ('uniqCombined64', 'OrDefault'), 'medianOrDefault': ('median', 'OrDefault'), 'last_valueOrDefault': ('last_value', 'OrDefault'), 'kolmogorovSmirnovTestOrDefault': ('kolmogorovSmirnovTest', 'OrDefault'), 'groupArrayLastOrDefault': ('groupArrayLast', 'OrDefault'), 'quantilesExactHighOrDefault': ('quantilesExactHigh', 'OrDefault'), 'cramersVBiasCorrectedOrDefault': ('cramersVBiasCorrected', 'OrDefault'), 'quantileTimingWeightedOrDefault': ('quantileTimingWeighted', 'OrDefault'), 'quantileTDigestWeightedOrDefault': ('quantileTDigestWeighted', 'OrDefault'), 'sumWithOverflowOrDefault': ('sumWithOverflow', 'OrDefault'), 'quantilesGKOrDefault': ('quantilesGK', 'OrDefault'), 'quantilesDeterministicOrDefault': ('quantilesDeterministic', 'OrDefault'), 'groupBitXorOrDefault': ('groupBitXor', 'OrDefault'), 'groupArrayInsertAtOrDefault': ('groupArrayInsertAt', 'OrDefault'), 'histogramOrDefault': ('histogram', 'OrDefault'), 'uniqHLL12OrDefault': ('uniqHLL12', 'OrDefault'), 'groupArrayMovingSumOrDefault': ('groupArrayMovingSum', 'OrDefault'), 'varSampOrDefault': ('varSamp', 'OrDefault'), 'welchTTestOrDefault': ('welchTTest', 'OrDefault'), 'exponentialTimeDecayedAvgOrDefault': ('exponentialTimeDecayedAvg', 'OrDefault'), 'groupArrayOrDefault': ('groupArray', 'OrDefault'), 'argMaxOrDefault': ('argMax', 'OrDefault'), 'quantileDeterministicOrDefault': ('quantileDeterministic', 'OrDefault'), 'categoricalInformationValueOrDefault': ('categoricalInformationValue', 'OrDefault'), 'deltaSumTimestampOrDefault': ('deltaSumTimestamp', 'OrDefault'), 'sumCountOrDefault': ('sumCount', 'OrDefault'), 'quantilesExactOrDefault': ('quantilesExact', 'OrDefault'), 'maxOrDefault': ('max', 'OrDefault'), 'quantilesBFloat16OrDefault': ('quantilesBFloat16', 'OrDefault'), 'sparkBarOrDefault': ('sparkBar', 'OrDefault'), 'minMapOrDefault': ('minMap', 'OrDefault'), 'simpleLinearRegressionOrDefault': ('simpleLinearRegression', 'OrDefault'), 'anyLastOrDefault': ('anyLast', 'OrDefault'), 'groupUniqArrayOrDefault': ('groupUniqArray', 'OrDefault'), 'groupBitmapXorOrDefault': ('groupBitmapXor', 'OrDefault'), 'topKWeightedOrDefault': ('topKWeighted', 'OrDefault'), 'quantilesTDigestOrDefault': ('quantilesTDigest', 'OrDefault'), 'groupBitOrOrDefault': ('groupBitOr', 'OrDefault'), 'groupArraySampleOrDefault': ('groupArraySample', 'OrDefault'), 'quantileTimingOrDefault': ('quantileTiming', 'OrDefault'), 'quantilesOrDefault': ('quantiles', 'OrDefault'), 'cramersVOrDefault': ('cramersV', 'OrDefault'), 'stochasticLinearRegressionOrDefault': ('stochasticLinearRegression', 'OrDefault'), 'theilsUOrDefault': ('theilsU', 'OrDefault'), 'varPopOrDefault': ('varPop', 'OrDefault'), 'stochasticLogisticRegressionOrDefault': ('stochasticLogisticRegression', 'OrDefault'), 'sumMapOrDefault': ('sumMap', 'OrDefault'), 'quantileOrDefault': ('quantile', 'OrDefault'), 'mannWhitneyUTestOrDefault': ('mannWhitneyUTest', 'OrDefault'), 'uniqCombinedOrDefault': ('uniqCombined', 'OrDefault'), 'uniqUpToOrDefault': ('uniqUpTo', 'OrDefault'), 'contingencyOrDefault': ('contingency', 'OrDefault'), 'quantilesBFloat16WeightedOrDefault': ('quantilesBFloat16Weighted', 'OrDefault'), 'uniqThetaOrDefault': ('uniqTheta', 'OrDefault'), 'quantilesExactWeightedOrDefault': ('quantilesExactWeighted', 'OrDefault'), 'uniqOrDefault': ('uniq', 'OrDefault'), 'countOrDefault': ('count', 'OrDefault'), 'quantileTDigestOrDefault': ('quantileTDigest', 'OrDefault'), 'skewSampOrDefault': ('skewSamp', 'OrDefault'), 'minOrDefault': ('min', 'OrDefault'), 'intervalLengthSumOrDefault': ('intervalLengthSum', 'OrDefault'), 'corrOrDefault': ('corr', 'OrDefault'), 'avgOrDefault': ('avg', 'OrDefault'), 'quantilesExactLowOrDefault': ('quantilesExactLow', 'OrDefault'), 'groupBitmapOrDefault': ('groupBitmap', 'OrDefault'), 'exponentialMovingAverageOrDefault': ('exponentialMovingAverage', 'OrDefault'), 'sequenceNextNodeOrDefault': ('sequenceNextNode', 'OrDefault'), 'first_valueOrDefault': ('first_value', 'OrDefault'), 'maxIntersectionsOrDefault': ('maxIntersections', 'OrDefault'), 'largestTriangleThreeBucketsOrDefault': ('largestTriangleThreeBuckets', 'OrDefault'), 'quantileExactWeightedOrDefault': ('quantileExactWeighted', 'OrDefault'), 'stddevSampOrDefault': ('stddevSamp', 'OrDefault'), 'groupBitAndOrDefault': ('groupBitAnd', 'OrDefault'), 'kurtPopOrDefault': ('kurtPop', 'OrDefault'), 'quantileGKOrDefault': ('quantileGK', 'OrDefault'), 'entropyOrDefault': ('entropy', 'OrDefault'), 'stddevPopOrDefault': ('stddevPop', 'OrDefault'), 'boundingRatioOrDefault': ('boundingRatio', 'OrDefault'), 'maxIntersectionsPositionOrDefault': ('maxIntersectionsPosition', 'OrDefault'), 'quantileExactOrDefault': ('quantileExact', 'OrDefault'), 'quantilesTimingOrDefault': ('quantilesTiming', 'OrDefault'), 'avgWeightedOrDefault': ('avgWeighted', 'OrDefault'), 'quantileInterpolatedWeightedOrDefault': ('quantileInterpolatedWeighted', 'OrDefault'), 'quantilesTimingWeightedOrDefault': ('quantilesTimingWeighted', 'OrDefault'), 'quantileExactLowOrDefault': ('quantileExactLow', 'OrDefault'), 'windowFunnelOrDefault': ('windowFunnel', 'OrDefault'), 'quantileBFloat16OrDefault': ('quantileBFloat16', 'OrDefault'), 'anyOrDefault': ('any', 'OrDefault'), 'kurtSampOrDefault': ('kurtSamp', 'OrDefault'), 'groupArrayMovingAvgOrDefault': ('groupArrayMovingAvg', 'OrDefault'), 'covarPopOrDefault': ('covarPop', 'OrDefault'), 'sumOrNull': ('sum', 'OrNull'), 'groupBitmapAndOrNull': ('groupBitmapAnd', 'OrNull'), 'retentionOrNull': ('retention', 'OrNull'), 'maxMapOrNull': ('maxMap', 'OrNull'), 'sumKahanOrNull': ('sumKahan', 'OrNull'), 'quantilesInterpolatedWeightedOrNull': ('quantilesInterpolatedWeighted', 'OrNull'), 'anyHeavyOrNull': ('anyHeavy', 'OrNull'), 'sequenceMatchOrNull': ('sequenceMatch', 'OrNull'), 'skewPopOrNull': ('skewPop', 'OrNull'), 'sequenceCountOrNull': ('sequenceCount', 'OrNull'), 'topKOrNull': ('topK', 'OrNull'), 'deltaSumOrNull': ('deltaSum', 'OrNull'), 'quantileBFloat16WeightedOrNull': ('quantileBFloat16Weighted', 'OrNull'), 'uniqExactOrNull': ('uniqExact', 'OrNull'), 'groupBitmapOrOrNull': ('groupBitmapOr', 'OrNull'), 'quantilesTDigestWeightedOrNull': ('quantilesTDigestWeighted', 'OrNull'), 'quantileExactHighOrNull': ('quantileExactHigh', 'OrNull'), 'argMinOrNull': ('argMin', 'OrNull'), 'rankCorrOrNull': ('rankCorr', 'OrNull'), 'covarSampOrNull': ('covarSamp', 'OrNull'), 'studentTTestOrNull': ('studentTTest', 'OrNull'), 'meanZTestOrNull': ('meanZTest', 'OrNull'), 'uniqCombined64OrNull': ('uniqCombined64', 'OrNull'), 'medianOrNull': ('median', 'OrNull'), 'last_valueOrNull': ('last_value', 'OrNull'), 'kolmogorovSmirnovTestOrNull': ('kolmogorovSmirnovTest', 'OrNull'), 'groupArrayLastOrNull': ('groupArrayLast', 'OrNull'), 'quantilesExactHighOrNull': ('quantilesExactHigh', 'OrNull'), 'cramersVBiasCorrectedOrNull': ('cramersVBiasCorrected', 'OrNull'), 'quantileTimingWeightedOrNull': ('quantileTimingWeighted', 'OrNull'), 'quantileTDigestWeightedOrNull': ('quantileTDigestWeighted', 'OrNull'), 'sumWithOverflowOrNull': ('sumWithOverflow', 'OrNull'), 'quantilesGKOrNull': ('quantilesGK', 'OrNull'), 'quantilesDeterministicOrNull': ('quantilesDeterministic', 'OrNull'), 'groupBitXorOrNull': ('groupBitXor', 'OrNull'), 'groupArrayInsertAtOrNull': ('groupArrayInsertAt', 'OrNull'), 'histogramOrNull': ('histogram', 'OrNull'), 'uniqHLL12OrNull': ('uniqHLL12', 'OrNull'), 'groupArrayMovingSumOrNull': ('groupArrayMovingSum', 'OrNull'), 'varSampOrNull': ('varSamp', 'OrNull'), 'welchTTestOrNull': ('welchTTest', 'OrNull'), 'exponentialTimeDecayedAvgOrNull': ('exponentialTimeDecayedAvg', 'OrNull'), 'groupArrayOrNull': ('groupArray', 'OrNull'), 'argMaxOrNull': ('argMax', 'OrNull'), 'quantileDeterministicOrNull': ('quantileDeterministic', 'OrNull'), 'categoricalInformationValueOrNull': ('categoricalInformationValue', 'OrNull'), 'deltaSumTimestampOrNull': ('deltaSumTimestamp', 'OrNull'), 'sumCountOrNull': ('sumCount', 'OrNull'), 'quantilesExactOrNull': ('quantilesExact', 'OrNull'), 'maxOrNull': ('max', 'OrNull'), 'quantilesBFloat16OrNull': ('quantilesBFloat16', 'OrNull'), 'sparkBarOrNull': ('sparkBar', 'OrNull'), 'minMapOrNull': ('minMap', 'OrNull'), 'simpleLinearRegressionOrNull': ('simpleLinearRegression', 'OrNull'), 'anyLastOrNull': ('anyLast', 'OrNull'), 'groupUniqArrayOrNull': ('groupUniqArray', 'OrNull'), 'groupBitmapXorOrNull': ('groupBitmapXor', 'OrNull'), 'topKWeightedOrNull': ('topKWeighted', 'OrNull'), 'quantilesTDigestOrNull': ('quantilesTDigest', 'OrNull'), 'groupBitOrOrNull': ('groupBitOr', 'OrNull'), 'groupArraySampleOrNull': ('groupArraySample', 'OrNull'), 'quantileTimingOrNull': ('quantileTiming', 'OrNull'), 'quantilesOrNull': ('quantiles', 'OrNull'), 'cramersVOrNull': ('cramersV', 'OrNull'), 'stochasticLinearRegressionOrNull': ('stochasticLinearRegression', 'OrNull'), 'theilsUOrNull': ('theilsU', 'OrNull'), 'varPopOrNull': ('varPop', 'OrNull'), 'stochasticLogisticRegressionOrNull': ('stochasticLogisticRegression', 'OrNull'), 'sumMapOrNull': ('sumMap', 'OrNull'), 'quantileOrNull': ('quantile', 'OrNull'), 'mannWhitneyUTestOrNull': ('mannWhitneyUTest', 'OrNull'), 'uniqCombinedOrNull': ('uniqCombined', 'OrNull'), 'uniqUpToOrNull': ('uniqUpTo', 'OrNull'), 'contingencyOrNull': ('contingency', 'OrNull'), 'quantilesBFloat16WeightedOrNull': ('quantilesBFloat16Weighted', 'OrNull'), 'uniqThetaOrNull': ('uniqTheta', 'OrNull'), 'quantilesExactWeightedOrNull': ('quantilesExactWeighted', 'OrNull'), 'uniqOrNull': ('uniq', 'OrNull'), 'countOrNull': ('count', 'OrNull'), 'quantileTDigestOrNull': ('quantileTDigest', 'OrNull'), 'skewSampOrNull': ('skewSamp', 'OrNull'), 'minOrNull': ('min', 'OrNull'), 'intervalLengthSumOrNull': ('intervalLengthSum', 'OrNull'), 'corrOrNull': ('corr', 'OrNull'), 'avgOrNull': ('avg', 'OrNull'), 'quantilesExactLowOrNull': ('quantilesExactLow', 'OrNull'), 'groupBitmapOrNull': ('groupBitmap', 'OrNull'), 'exponentialMovingAverageOrNull': ('exponentialMovingAverage', 'OrNull'), 'sequenceNextNodeOrNull': ('sequenceNextNode', 'OrNull'), 'first_valueOrNull': ('first_value', 'OrNull'), 'maxIntersectionsOrNull': ('maxIntersections', 'OrNull'), 'largestTriangleThreeBucketsOrNull': ('largestTriangleThreeBuckets', 'OrNull'), 'quantileExactWeightedOrNull': ('quantileExactWeighted', 'OrNull'), 'stddevSampOrNull': ('stddevSamp', 'OrNull'), 'groupBitAndOrNull': ('groupBitAnd', 'OrNull'), 'kurtPopOrNull': ('kurtPop', 'OrNull'), 'quantileGKOrNull': ('quantileGK', 'OrNull'), 'entropyOrNull': ('entropy', 'OrNull'), 'stddevPopOrNull': ('stddevPop', 'OrNull'), 'boundingRatioOrNull': ('boundingRatio', 'OrNull'), 'maxIntersectionsPositionOrNull': ('maxIntersectionsPosition', 'OrNull'), 'quantileExactOrNull': ('quantileExact', 'OrNull'), 'quantilesTimingOrNull': ('quantilesTiming', 'OrNull'), 'avgWeightedOrNull': ('avgWeighted', 'OrNull'), 'quantileInterpolatedWeightedOrNull': ('quantileInterpolatedWeighted', 'OrNull'), 'quantilesTimingWeightedOrNull': ('quantilesTimingWeighted', 'OrNull'), 'quantileExactLowOrNull': ('quantileExactLow', 'OrNull'), 'windowFunnelOrNull': ('windowFunnel', 'OrNull'), 'quantileBFloat16OrNull': ('quantileBFloat16', 'OrNull'), 'anyOrNull': ('any', 'OrNull'), 'kurtSampOrNull': ('kurtSamp', 'OrNull'), 'groupArrayMovingAvgOrNull': ('groupArrayMovingAvg', 'OrNull'), 'covarPopOrNull': ('covarPop', 'OrNull'), 'sumResample': ('sum', 'Resample'), 'groupBitmapAndResample': ('groupBitmapAnd', 'Resample'), 'retentionResample': ('retention', 'Resample'), 'maxMapResample': ('maxMap', 'Resample'), 'sumKahanResample': ('sumKahan', 'Resample'), 'quantilesInterpolatedWeightedResample': ('quantilesInterpolatedWeighted', 'Resample'), 'anyHeavyResample': ('anyHeavy', 'Resample'), 'sequenceMatchResample': ('sequenceMatch', 'Resample'), 'skewPopResample': ('skewPop', 'Resample'), 'sequenceCountResample': ('sequenceCount', 'Resample'), 'topKResample': ('topK', 'Resample'), 'deltaSumResample': ('deltaSum', 'Resample'), 'quantileBFloat16WeightedResample': ('quantileBFloat16Weighted', 'Resample'), 'uniqExactResample': ('uniqExact', 'Resample'), 'groupBitmapOrResample': ('groupBitmapOr', 'Resample'), 'quantilesTDigestWeightedResample': ('quantilesTDigestWeighted', 'Resample'), 'quantileExactHighResample': ('quantileExactHigh', 'Resample'), 'argMinResample': ('argMin', 'Resample'), 'rankCorrResample': ('rankCorr', 'Resample'), 'covarSampResample': ('covarSamp', 'Resample'), 'studentTTestResample': ('studentTTest', 'Resample'), 'meanZTestResample': ('meanZTest', 'Resample'), 'uniqCombined64Resample': ('uniqCombined64', 'Resample'), 'medianResample': ('median', 'Resample'), 'last_valueResample': ('last_value', 'Resample'), 'kolmogorovSmirnovTestResample': ('kolmogorovSmirnovTest', 'Resample'), 'groupArrayLastResample': ('groupArrayLast', 'Resample'), 'quantilesExactHighResample': ('quantilesExactHigh', 'Resample'), 'cramersVBiasCorrectedResample': ('cramersVBiasCorrected', 'Resample'), 'quantileTimingWeightedResample': ('quantileTimingWeighted', 'Resample'), 'quantileTDigestWeightedResample': ('quantileTDigestWeighted', 'Resample'), 'sumWithOverflowResample': ('sumWithOverflow', 'Resample'), 'quantilesGKResample': ('quantilesGK', 'Resample'), 'quantilesDeterministicResample': ('quantilesDeterministic', 'Resample'), 'groupBitXorResample': ('groupBitXor', 'Resample'), 'groupArrayInsertAtResample': ('groupArrayInsertAt', 'Resample'), 'histogramResample': ('histogram', 'Resample'), 'uniqHLL12Resample': ('uniqHLL12', 'Resample'), 'groupArrayMovingSumResample': ('groupArrayMovingSum', 'Resample'), 'varSampResample': ('varSamp', 'Resample'), 'welchTTestResample': ('welchTTest', 'Resample'), 'exponentialTimeDecayedAvgResample': ('exponentialTimeDecayedAvg', 'Resample'), 'groupArrayResample': ('groupArray', 'Resample'), 'argMaxResample': ('argMax', 'Resample'), 'quantileDeterministicResample': ('quantileDeterministic', 'Resample'), 'categoricalInformationValueResample': ('categoricalInformationValue', 'Resample'), 'deltaSumTimestampResample': ('deltaSumTimestamp', 'Resample'), 'sumCountResample': ('sumCount', 'Resample'), 'quantilesExactResample': ('quantilesExact', 'Resample'), 'maxResample': ('max', 'Resample'), 'quantilesBFloat16Resample': ('quantilesBFloat16', 'Resample'), 'sparkBarResample': ('sparkBar', 'Resample'), 'minMapResample': ('minMap', 'Resample'), 'simpleLinearRegressionResample': ('simpleLinearRegression', 'Resample'), 'anyLastResample': ('anyLast', 'Resample'), 'groupUniqArrayResample': ('groupUniqArray', 'Resample'), 'groupBitmapXorResample': ('groupBitmapXor', 'Resample'), 'topKWeightedResample': ('topKWeighted', 'Resample'), 'quantilesTDigestResample': ('quantilesTDigest', 'Resample'), 'groupBitOrResample': ('groupBitOr', 'Resample'), 'groupArraySampleResample': ('groupArraySample', 'Resample'), 'quantileTimingResample': ('quantileTiming', 'Resample'), 'quantilesResample': ('quantiles', 'Resample'), 'cramersVResample': ('cramersV', 'Resample'), 'stochasticLinearRegressionResample': ('stochasticLinearRegression', 'Resample'), 'theilsUResample': ('theilsU', 'Resample'), 'varPopResample': ('varPop', 'Resample'), 'stochasticLogisticRegressionResample': ('stochasticLogisticRegression', 'Resample'), 'sumMapResample': ('sumMap', 'Resample'), 'quantileResample': ('quantile', 'Resample'), 'mannWhitneyUTestResample': ('mannWhitneyUTest', 'Resample'), 'uniqCombinedResample': ('uniqCombined', 'Resample'), 'uniqUpToResample': ('uniqUpTo', 'Resample'), 'contingencyResample': ('contingency', 'Resample'), 'quantilesBFloat16WeightedResample': ('quantilesBFloat16Weighted', 'Resample'), 'uniqThetaResample': ('uniqTheta', 'Resample'), 'quantilesExactWeightedResample': ('quantilesExactWeighted', 'Resample'), 'uniqResample': ('uniq', 'Resample'), 'countResample': ('count', 'Resample'), 'quantileTDigestResample': ('quantileTDigest', 'Resample'), 'skewSampResample': ('skewSamp', 'Resample'), 'minResample': ('min', 'Resample'), 'intervalLengthSumResample': ('intervalLengthSum', 'Resample'), 'corrResample': ('corr', 'Resample'), 'avgResample': ('avg', 'Resample'), 'quantilesExactLowResample': ('quantilesExactLow', 'Resample'), 'groupBitmapResample': ('groupBitmap', 'Resample'), 'exponentialMovingAverageResample': ('exponentialMovingAverage', 'Resample'), 'sequenceNextNodeResample': ('sequenceNextNode', 'Resample'), 'first_valueResample': ('first_value', 'Resample'), 'maxIntersectionsResample': ('maxIntersections', 'Resample'), 'largestTriangleThreeBucketsResample': ('largestTriangleThreeBuckets', 'Resample'), 'quantileExactWeightedResample': ('quantileExactWeighted', 'Resample'), 'stddevSampResample': ('stddevSamp', 'Resample'), 'groupBitAndResample': ('groupBitAnd', 'Resample'), 'kurtPopResample': ('kurtPop', 'Resample'), 'quantileGKResample': ('quantileGK', 'Resample'), 'entropyResample': ('entropy', 'Resample'), 'stddevPopResample': ('stddevPop', 'Resample'), 'boundingRatioResample': ('boundingRatio', 'Resample'), 'maxIntersectionsPositionResample': ('maxIntersectionsPosition', 'Resample'), 'quantileExactResample': ('quantileExact', 'Resample'), 'quantilesTimingResample': ('quantilesTiming', 'Resample'), 'avgWeightedResample': ('avgWeighted', 'Resample'), 'quantileInterpolatedWeightedResample': ('quantileInterpolatedWeighted', 'Resample'), 'quantilesTimingWeightedResample': ('quantilesTimingWeighted', 'Resample'), 'quantileExactLowResample': ('quantileExactLow', 'Resample'), 'windowFunnelResample': ('windowFunnel', 'Resample'), 'quantileBFloat16Resample': ('quantileBFloat16', 'Resample'), 'anyResample': ('any', 'Resample'), 'kurtSampResample': ('kurtSamp', 'Resample'), 'groupArrayMovingAvgResample': ('groupArrayMovingAvg', 'Resample'), 'covarPopResample': ('covarPop', 'Resample'), 'sumArgMin': ('sum', 'ArgMin'), 'groupBitmapAndArgMin': ('groupBitmapAnd', 'ArgMin'), 'retentionArgMin': ('retention', 'ArgMin'), 'maxMapArgMin': ('maxMap', 'ArgMin'), 'sumKahanArgMin': ('sumKahan', 'ArgMin'), 'quantilesInterpolatedWeightedArgMin': ('quantilesInterpolatedWeighted', 'ArgMin'), 'anyHeavyArgMin': ('anyHeavy', 'ArgMin'), 'sequenceMatchArgMin': ('sequenceMatch', 'ArgMin'), 'skewPopArgMin': ('skewPop', 'ArgMin'), 'sequenceCountArgMin': ('sequenceCount', 'ArgMin'), 'topKArgMin': ('topK', 'ArgMin'), 'deltaSumArgMin': ('deltaSum', 'ArgMin'), 'quantileBFloat16WeightedArgMin': ('quantileBFloat16Weighted', 'ArgMin'), 'uniqExactArgMin': ('uniqExact', 'ArgMin'), 'groupBitmapOrArgMin': ('groupBitmapOr', 'ArgMin'), 'quantilesTDigestWeightedArgMin': ('quantilesTDigestWeighted', 'ArgMin'), 'quantileExactHighArgMin': ('quantileExactHigh', 'ArgMin'), 'argMinArgMin': ('argMin', 'ArgMin'), 'rankCorrArgMin': ('rankCorr', 'ArgMin'), 'covarSampArgMin': ('covarSamp', 'ArgMin'), 'studentTTestArgMin': ('studentTTest', 'ArgMin'), 'meanZTestArgMin': ('meanZTest', 'ArgMin'), 'uniqCombined64ArgMin': ('uniqCombined64', 'ArgMin'), 'medianArgMin': ('median', 'ArgMin'), 'last_valueArgMin': ('last_value', 'ArgMin'), 'kolmogorovSmirnovTestArgMin': ('kolmogorovSmirnovTest', 'ArgMin'), 'groupArrayLastArgMin': ('groupArrayLast', 'ArgMin'), 'quantilesExactHighArgMin': ('quantilesExactHigh', 'ArgMin'), 'cramersVBiasCorrectedArgMin': ('cramersVBiasCorrected', 'ArgMin'), 'quantileTimingWeightedArgMin': ('quantileTimingWeighted', 'ArgMin'), 'quantileTDigestWeightedArgMin': ('quantileTDigestWeighted', 'ArgMin'), 'sumWithOverflowArgMin': ('sumWithOverflow', 'ArgMin'), 'quantilesGKArgMin': ('quantilesGK', 'ArgMin'), 'quantilesDeterministicArgMin': ('quantilesDeterministic', 'ArgMin'), 'groupBitXorArgMin': ('groupBitXor', 'ArgMin'), 'groupArrayInsertAtArgMin': ('groupArrayInsertAt', 'ArgMin'), 'histogramArgMin': ('histogram', 'ArgMin'), 'uniqHLL12ArgMin': ('uniqHLL12', 'ArgMin'), 'groupArrayMovingSumArgMin': ('groupArrayMovingSum', 'ArgMin'), 'varSampArgMin': ('varSamp', 'ArgMin'), 'welchTTestArgMin': ('welchTTest', 'ArgMin'), 'exponentialTimeDecayedAvgArgMin': ('exponentialTimeDecayedAvg', 'ArgMin'), 'groupArrayArgMin': ('groupArray', 'ArgMin'), 'argMaxArgMin': ('argMax', 'ArgMin'), 'quantileDeterministicArgMin': ('quantileDeterministic', 'ArgMin'), 'categoricalInformationValueArgMin': ('categoricalInformationValue', 'ArgMin'), 'deltaSumTimestampArgMin': ('deltaSumTimestamp', 'ArgMin'), 'sumCountArgMin': ('sumCount', 'ArgMin'), 'quantilesExactArgMin': ('quantilesExact', 'ArgMin'), 'maxArgMin': ('max', 'ArgMin'), 'quantilesBFloat16ArgMin': ('quantilesBFloat16', 'ArgMin'), 'sparkBarArgMin': ('sparkBar', 'ArgMin'), 'minMapArgMin': ('minMap', 'ArgMin'), 'simpleLinearRegressionArgMin': ('simpleLinearRegression', 'ArgMin'), 'anyLastArgMin': ('anyLast', 'ArgMin'), 'groupUniqArrayArgMin': ('groupUniqArray', 'ArgMin'), 'groupBitmapXorArgMin': ('groupBitmapXor', 'ArgMin'), 'topKWeightedArgMin': ('topKWeighted', 'ArgMin'), 'quantilesTDigestArgMin': ('quantilesTDigest', 'ArgMin'), 'groupBitOrArgMin': ('groupBitOr', 'ArgMin'), 'groupArraySampleArgMin': ('groupArraySample', 'ArgMin'), 'quantileTimingArgMin': ('quantileTiming', 'ArgMin'), 'quantilesArgMin': ('quantiles', 'ArgMin'), 'cramersVArgMin': ('cramersV', 'ArgMin'), 'stochasticLinearRegressionArgMin': ('stochasticLinearRegression', 'ArgMin'), 'theilsUArgMin': ('theilsU', 'ArgMin'), 'varPopArgMin': ('varPop', 'ArgMin'), 'stochasticLogisticRegressionArgMin': ('stochasticLogisticRegression', 'ArgMin'), 'sumMapArgMin': ('sumMap', 'ArgMin'), 'quantileArgMin': ('quantile', 'ArgMin'), 'mannWhitneyUTestArgMin': ('mannWhitneyUTest', 'ArgMin'), 'uniqCombinedArgMin': ('uniqCombined', 'ArgMin'), 'uniqUpToArgMin': ('uniqUpTo', 'ArgMin'), 'contingencyArgMin': ('contingency', 'ArgMin'), 'quantilesBFloat16WeightedArgMin': ('quantilesBFloat16Weighted', 'ArgMin'), 'uniqThetaArgMin': ('uniqTheta', 'ArgMin'), 'quantilesExactWeightedArgMin': ('quantilesExactWeighted', 'ArgMin'), 'uniqArgMin': ('uniq', 'ArgMin'), 'countArgMin': ('count', 'ArgMin'), 'quantileTDigestArgMin': ('quantileTDigest', 'ArgMin'), 'skewSampArgMin': ('skewSamp', 'ArgMin'), 'minArgMin': ('min', 'ArgMin'), 'intervalLengthSumArgMin': ('intervalLengthSum', 'ArgMin'), 'corrArgMin': ('corr', 'ArgMin'), 'avgArgMin': ('avg', 'ArgMin'), 'quantilesExactLowArgMin': ('quantilesExactLow', 'ArgMin'), 'groupBitmapArgMin': ('groupBitmap', 'ArgMin'), 'exponentialMovingAverageArgMin': ('exponentialMovingAverage', 'ArgMin'), 'sequenceNextNodeArgMin': ('sequenceNextNode', 'ArgMin'), 'first_valueArgMin': ('first_value', 'ArgMin'), 'maxIntersectionsArgMin': ('maxIntersections', 'ArgMin'), 'largestTriangleThreeBucketsArgMin': ('largestTriangleThreeBuckets', 'ArgMin'), 'quantileExactWeightedArgMin': ('quantileExactWeighted', 'ArgMin'), 'stddevSampArgMin': ('stddevSamp', 'ArgMin'), 'groupBitAndArgMin': ('groupBitAnd', 'ArgMin'), 'kurtPopArgMin': ('kurtPop', 'ArgMin'), 'quantileGKArgMin': ('quantileGK', 'ArgMin'), 'entropyArgMin': ('entropy', 'ArgMin'), 'stddevPopArgMin': ('stddevPop', 'ArgMin'), 'boundingRatioArgMin': ('boundingRatio', 'ArgMin'), 'maxIntersectionsPositionArgMin': ('maxIntersectionsPosition', 'ArgMin'), 'quantileExactArgMin': ('quantileExact', 'ArgMin'), 'quantilesTimingArgMin': ('quantilesTiming', 'ArgMin'), 'avgWeightedArgMin': ('avgWeighted', 'ArgMin'), 'quantileInterpolatedWeightedArgMin': ('quantileInterpolatedWeighted', 'ArgMin'), 'quantilesTimingWeightedArgMin': ('quantilesTimingWeighted', 'ArgMin'), 'quantileExactLowArgMin': ('quantileExactLow', 'ArgMin'), 'windowFunnelArgMin': ('windowFunnel', 'ArgMin'), 'quantileBFloat16ArgMin': ('quantileBFloat16', 'ArgMin'), 'anyArgMin': ('any', 'ArgMin'), 'kurtSampArgMin': ('kurtSamp', 'ArgMin'), 'groupArrayMovingAvgArgMin': ('groupArrayMovingAvg', 'ArgMin'), 'covarPopArgMin': ('covarPop', 'ArgMin'), 'sumArgMax': ('sum', 'ArgMax'), 'groupBitmapAndArgMax': ('groupBitmapAnd', 'ArgMax'), 'retentionArgMax': ('retention', 'ArgMax'), 'maxMapArgMax': ('maxMap', 'ArgMax'), 'sumKahanArgMax': ('sumKahan', 'ArgMax'), 'quantilesInterpolatedWeightedArgMax': ('quantilesInterpolatedWeighted', 'ArgMax'), 'anyHeavyArgMax': ('anyHeavy', 'ArgMax'), 'sequenceMatchArgMax': ('sequenceMatch', 'ArgMax'), 'skewPopArgMax': ('skewPop', 'ArgMax'), 'sequenceCountArgMax': ('sequenceCount', 'ArgMax'), 'topKArgMax': ('topK', 'ArgMax'), 'deltaSumArgMax': ('deltaSum', 'ArgMax'), 'quantileBFloat16WeightedArgMax': ('quantileBFloat16Weighted', 'ArgMax'), 'uniqExactArgMax': ('uniqExact', 'ArgMax'), 'groupBitmapOrArgMax': ('groupBitmapOr', 'ArgMax'), 'quantilesTDigestWeightedArgMax': ('quantilesTDigestWeighted', 'ArgMax'), 'quantileExactHighArgMax': ('quantileExactHigh', 'ArgMax'), 'argMinArgMax': ('argMin', 'ArgMax'), 'rankCorrArgMax': ('rankCorr', 'ArgMax'), 'covarSampArgMax': ('covarSamp', 'ArgMax'), 'studentTTestArgMax': ('studentTTest', 'ArgMax'), 'meanZTestArgMax': ('meanZTest', 'ArgMax'), 'uniqCombined64ArgMax': ('uniqCombined64', 'ArgMax'), 'medianArgMax': ('median', 'ArgMax'), 'last_valueArgMax': ('last_value', 'ArgMax'), 'kolmogorovSmirnovTestArgMax': ('kolmogorovSmirnovTest', 'ArgMax'), 'groupArrayLastArgMax': ('groupArrayLast', 'ArgMax'), 'quantilesExactHighArgMax': ('quantilesExactHigh', 'ArgMax'), 'cramersVBiasCorrectedArgMax': ('cramersVBiasCorrected', 'ArgMax'), 'quantileTimingWeightedArgMax': ('quantileTimingWeighted', 'ArgMax'), 'quantileTDigestWeightedArgMax': ('quantileTDigestWeighted', 'ArgMax'), 'sumWithOverflowArgMax': ('sumWithOverflow', 'ArgMax'), 'quantilesGKArgMax': ('quantilesGK', 'ArgMax'), 'quantilesDeterministicArgMax': ('quantilesDeterministic', 'ArgMax'), 'groupBitXorArgMax': ('groupBitXor', 'ArgMax'), 'groupArrayInsertAtArgMax': ('groupArrayInsertAt', 'ArgMax'), 'histogramArgMax': ('histogram', 'ArgMax'), 'uniqHLL12ArgMax': ('uniqHLL12', 'ArgMax'), 'groupArrayMovingSumArgMax': ('groupArrayMovingSum', 'ArgMax'), 'varSampArgMax': ('varSamp', 'ArgMax'), 'welchTTestArgMax': ('welchTTest', 'ArgMax'), 'exponentialTimeDecayedAvgArgMax': ('exponentialTimeDecayedAvg', 'ArgMax'), 'groupArrayArgMax': ('groupArray', 'ArgMax'), 'argMaxArgMax': ('argMax', 'ArgMax'), 'quantileDeterministicArgMax': ('quantileDeterministic', 'ArgMax'), 'categoricalInformationValueArgMax': ('categoricalInformationValue', 'ArgMax'), 'deltaSumTimestampArgMax': ('deltaSumTimestamp', 'ArgMax'), 'sumCountArgMax': ('sumCount', 'ArgMax'), 'quantilesExactArgMax': ('quantilesExact', 'ArgMax'), 'maxArgMax': ('max', 'ArgMax'), 'quantilesBFloat16ArgMax': ('quantilesBFloat16', 'ArgMax'), 'sparkBarArgMax': ('sparkBar', 'ArgMax'), 'minMapArgMax': ('minMap', 'ArgMax'), 'simpleLinearRegressionArgMax': ('simpleLinearRegression', 'ArgMax'), 'anyLastArgMax': ('anyLast', 'ArgMax'), 'groupUniqArrayArgMax': ('groupUniqArray', 'ArgMax'), 'groupBitmapXorArgMax': ('groupBitmapXor', 'ArgMax'), 'topKWeightedArgMax': ('topKWeighted', 'ArgMax'), 'quantilesTDigestArgMax': ('quantilesTDigest', 'ArgMax'), 'groupBitOrArgMax': ('groupBitOr', 'ArgMax'), 'groupArraySampleArgMax': ('groupArraySample', 'ArgMax'), 'quantileTimingArgMax': ('quantileTiming', 'ArgMax'), 'quantilesArgMax': ('quantiles', 'ArgMax'), 'cramersVArgMax': ('cramersV', 'ArgMax'), 'stochasticLinearRegressionArgMax': ('stochasticLinearRegression', 'ArgMax'), 'theilsUArgMax': ('theilsU', 'ArgMax'), 'varPopArgMax': ('varPop', 'ArgMax'), 'stochasticLogisticRegressionArgMax': ('stochasticLogisticRegression', 'ArgMax'), 'sumMapArgMax': ('sumMap', 'ArgMax'), 'quantileArgMax': ('quantile', 'ArgMax'), 'mannWhitneyUTestArgMax': ('mannWhitneyUTest', 'ArgMax'), 'uniqCombinedArgMax': ('uniqCombined', 'ArgMax'), 'uniqUpToArgMax': ('uniqUpTo', 'ArgMax'), 'contingencyArgMax': ('contingency', 'ArgMax'), 'quantilesBFloat16WeightedArgMax': ('quantilesBFloat16Weighted', 'ArgMax'), 'uniqThetaArgMax': ('uniqTheta', 'ArgMax'), 'quantilesExactWeightedArgMax': ('quantilesExactWeighted', 'ArgMax'), 'uniqArgMax': ('uniq', 'ArgMax'), 'countArgMax': ('count', 'ArgMax'), 'quantileTDigestArgMax': ('quantileTDigest', 'ArgMax'), 'skewSampArgMax': ('skewSamp', 'ArgMax'), 'minArgMax': ('min', 'ArgMax'), 'intervalLengthSumArgMax': ('intervalLengthSum', 'ArgMax'), 'corrArgMax': ('corr', 'ArgMax'), 'avgArgMax': ('avg', 'ArgMax'), 'quantilesExactLowArgMax': ('quantilesExactLow', 'ArgMax'), 'groupBitmapArgMax': ('groupBitmap', 'ArgMax'), 'exponentialMovingAverageArgMax': ('exponentialMovingAverage', 'ArgMax'), 'sequenceNextNodeArgMax': ('sequenceNextNode', 'ArgMax'), 'first_valueArgMax': ('first_value', 'ArgMax'), 'maxIntersectionsArgMax': ('maxIntersections', 'ArgMax'), 'largestTriangleThreeBucketsArgMax': ('largestTriangleThreeBuckets', 'ArgMax'), 'quantileExactWeightedArgMax': ('quantileExactWeighted', 'ArgMax'), 'stddevSampArgMax': ('stddevSamp', 'ArgMax'), 'groupBitAndArgMax': ('groupBitAnd', 'ArgMax'), 'kurtPopArgMax': ('kurtPop', 'ArgMax'), 'quantileGKArgMax': ('quantileGK', 'ArgMax'), 'entropyArgMax': ('entropy', 'ArgMax'), 'stddevPopArgMax': ('stddevPop', 'ArgMax'), 'boundingRatioArgMax': ('boundingRatio', 'ArgMax'), 'maxIntersectionsPositionArgMax': ('maxIntersectionsPosition', 'ArgMax'), 'quantileExactArgMax': ('quantileExact', 'ArgMax'), 'quantilesTimingArgMax': ('quantilesTiming', 'ArgMax'), 'avgWeightedArgMax': ('avgWeighted', 'ArgMax'), 'quantileInterpolatedWeightedArgMax': ('quantileInterpolatedWeighted', 'ArgMax'), 'quantilesTimingWeightedArgMax': ('quantilesTimingWeighted', 'ArgMax'), 'quantileExactLowArgMax': ('quantileExactLow', 'ArgMax'), 'windowFunnelArgMax': ('windowFunnel', 'ArgMax'), 'quantileBFloat16ArgMax': ('quantileBFloat16', 'ArgMax'), 'anyArgMax': ('any', 'ArgMax'), 'kurtSampArgMax': ('kurtSamp', 'ArgMax'), 'groupArrayMovingAvgArgMax': ('groupArrayMovingAvg', 'ArgMax'), 'covarPopArgMax': ('covarPop', 'ArgMax'), 'sum': ('sum', ''), 'groupBitmapAnd': ('groupBitmapAnd', ''), 'retention': ('retention', ''), 'sumKahan': ('sumKahan', ''), 'quantilesInterpolatedWeighted': ('quantilesInterpolatedWeighted', ''), 'anyHeavy': ('anyHeavy', ''), 'sequenceMatch': ('sequenceMatch', ''), 'skewPop': ('skewPop', ''), 'sequenceCount': ('sequenceCount', ''), 'topK': ('topK', ''), 'deltaSum': ('deltaSum', ''), 'quantileBFloat16Weighted': ('quantileBFloat16Weighted', ''), 'uniqExact': ('uniqExact', ''), 'groupBitmapOr': ('groupBitmapOr', ''), 'quantilesTDigestWeighted': ('quantilesTDigestWeighted', ''), 'quantileExactHigh': ('quantileExactHigh', ''), 'argMin': ('argMin', ''), 'rankCorr': ('rankCorr', ''), 'covarSamp': ('covarSamp', ''), 'studentTTest': ('studentTTest', ''), 'meanZTest': ('meanZTest', ''), 'uniqCombined64': ('uniqCombined64', ''), 'median': ('median', ''), 'last_value': ('last_value', ''), 'kolmogorovSmirnovTest': ('kolmogorovSmirnovTest', ''), 'groupArrayLast': ('groupArrayLast', ''), 'quantilesExactHigh': ('quantilesExactHigh', ''), 'cramersVBiasCorrected': ('cramersVBiasCorrected', ''), 'quantileTimingWeighted': ('quantileTimingWeighted', ''), 'quantileTDigestWeighted': ('quantileTDigestWeighted', ''), 'sumWithOverflow': ('sumWithOverflow', ''), 'quantilesGK': ('quantilesGK', ''), 'quantilesDeterministic': ('quantilesDeterministic', ''), 'groupBitXor': ('groupBitXor', ''), 'groupArrayInsertAt': ('groupArrayInsertAt', ''), 'histogram': ('histogram', ''), 'uniqHLL12': ('uniqHLL12', ''), 'groupArrayMovingSum': ('groupArrayMovingSum', ''), 'varSamp': ('varSamp', ''), 'welchTTest': ('welchTTest', ''), 'exponentialTimeDecayedAvg': ('exponentialTimeDecayedAvg', ''), 'groupArray': ('groupArray', ''), 'argMax': ('argMax', ''), 'quantileDeterministic': ('quantileDeterministic', ''), 'categoricalInformationValue': ('categoricalInformationValue', ''), 'deltaSumTimestamp': ('deltaSumTimestamp', ''), 'sumCount': ('sumCount', ''), 'quantilesExact': ('quantilesExact', ''), 'max': ('max', ''), 'quantilesBFloat16': ('quantilesBFloat16', ''), 'sparkBar': ('sparkBar', ''), 'simpleLinearRegression': ('simpleLinearRegression', ''), 'anyLast': ('anyLast', ''), 'groupUniqArray': ('groupUniqArray', ''), 'groupBitmapXor': ('groupBitmapXor', ''), 'topKWeighted': ('topKWeighted', ''), 'quantilesTDigest': ('quantilesTDigest', ''), 'groupBitOr': ('groupBitOr', ''), 'groupArraySample': ('groupArraySample', ''), 'quantileTiming': ('quantileTiming', ''), 'quantiles': ('quantiles', ''), 'cramersV': ('cramersV', ''), 'stochasticLinearRegression': ('stochasticLinearRegression', ''), 'theilsU': ('theilsU', ''), 'varPop': ('varPop', ''), 'stochasticLogisticRegression': ('stochasticLogisticRegression', ''), 'quantile': ('quantile', ''), 'mannWhitneyUTest': ('mannWhitneyUTest', ''), 'uniqCombined': ('uniqCombined', ''), 'uniqUpTo': ('uniqUpTo', ''), 'contingency': ('contingency', ''), 'quantilesBFloat16Weighted': ('quantilesBFloat16Weighted', ''), 'uniqTheta': ('uniqTheta', ''), 'quantilesExactWeighted': ('quantilesExactWeighted', ''), 'uniq': ('uniq', ''), 'count': ('count', ''), 'quantileTDigest': ('quantileTDigest', ''), 'skewSamp': ('skewSamp', ''), 'min': ('min', ''), 'intervalLengthSum': ('intervalLengthSum', ''), 'corr': ('corr', ''), 'avg': ('avg', ''), 'quantilesExactLow': ('quantilesExactLow', ''), 'groupBitmap': ('groupBitmap', ''), 'exponentialMovingAverage': ('exponentialMovingAverage', ''), 'sequenceNextNode': ('sequenceNextNode', ''), 'first_value': ('first_value', ''), 'maxIntersections': ('maxIntersections', ''), 'largestTriangleThreeBuckets': ('largestTriangleThreeBuckets', ''), 'quantileExactWeighted': ('quantileExactWeighted', ''), 'stddevSamp': ('stddevSamp', ''), 'groupBitAnd': ('groupBitAnd', ''), 'kurtPop': ('kurtPop', ''), 'quantileGK': ('quantileGK', ''), 'entropy': ('entropy', ''), 'stddevPop': ('stddevPop', ''), 'boundingRatio': ('boundingRatio', ''), 'maxIntersectionsPosition': ('maxIntersectionsPosition', ''), 'quantileExact': ('quantileExact', ''), 'quantilesTiming': ('quantilesTiming', ''), 'avgWeighted': ('avgWeighted', ''), 'quantileInterpolatedWeighted': ('quantileInterpolatedWeighted', ''), 'quantilesTimingWeighted': ('quantilesTimingWeighted', ''), 'quantileExactLow': ('quantileExactLow', ''), 'windowFunnel': ('windowFunnel', ''), 'quantileBFloat16': ('quantileBFloat16', ''), 'any': ('any', ''), 'kurtSamp': ('kurtSamp', ''), 'groupArrayMovingAvg': ('groupArrayMovingAvg', ''), 'covarPop': ('covarPop', '')}
FUNCTIONS_WITH_ALIASED_ARGS = {'TUPLE', 'STRUCT'}
FUNCTION_PARSERS = {'CAST': <function Parser.<lambda>>, 'CONVERT': <function Parser.<lambda>>, 'DECODE': <function Parser.<lambda>>, 'EXTRACT': <function Parser.<lambda>>, 'JSON_OBJECT': <function Parser.<lambda>>, 'JSON_OBJECTAGG': <function Parser.<lambda>>, 'JSON_TABLE': <function Parser.<lambda>>, 'OPENJSON': <function Parser.<lambda>>, 'POSITION': <function Parser.<lambda>>, 'PREDICT': <function Parser.<lambda>>, 'SAFE_CAST': <function Parser.<lambda>>, 'STRING_AGG': <function Parser.<lambda>>, 'SUBSTRING': <function Parser.<lambda>>, 'TRIM': <function Parser.<lambda>>, 'TRY_CAST': <function Parser.<lambda>>, 'TRY_CONVERT': <function Parser.<lambda>>, 'ARRAYJOIN': <function ClickHouse.Parser.<lambda>>, 'QUANTILE': <function ClickHouse.Parser.<lambda>>}
NO_PAREN_FUNCTION_PARSERS = {'CASE': <function Parser.<lambda>>, 'IF': <function Parser.<lambda>>, 'NEXT': <function Parser.<lambda>>}
RANGE_PARSERS = {<TokenType.BETWEEN: 'BETWEEN'>: <function Parser.<lambda>>, <TokenType.GLOB: 'GLOB'>: <function binary_range_parser.<locals>.<lambda>>, <TokenType.ILIKE: 'ILIKE'>: <function binary_range_parser.<locals>.<lambda>>, <TokenType.IN: 'IN'>: <function Parser.<lambda>>, <TokenType.IRLIKE: 'IRLIKE'>: <function binary_range_parser.<locals>.<lambda>>, <TokenType.IS: 'IS'>: <function Parser.<lambda>>, <TokenType.LIKE: 'LIKE'>: <function binary_range_parser.<locals>.<lambda>>, <TokenType.OVERLAPS: 'OVERLAPS'>: <function binary_range_parser.<locals>.<lambda>>, <TokenType.RLIKE: 'RLIKE'>: <function binary_range_parser.<locals>.<lambda>>, <TokenType.SIMILAR_TO: 'SIMILAR_TO'>: <function binary_range_parser.<locals>.<lambda>>, <TokenType.FOR: 'FOR'>: <function Parser.<lambda>>, <TokenType.GLOBAL: 'GLOBAL'>: <function ClickHouse.Parser.<lambda>>}
COLUMN_OPERATORS = {<TokenType.DOT: 'DOT'>: None, <TokenType.DCOLON: 'DCOLON'>: <function Parser.<lambda>>, <TokenType.ARROW: 'ARROW'>: <function Parser.<lambda>>, <TokenType.DARROW: 'DARROW'>: <function Parser.<lambda>>, <TokenType.HASH_ARROW: 'HASH_ARROW'>: <function Parser.<lambda>>, <TokenType.DHASH_ARROW: 'DHASH_ARROW'>: <function Parser.<lambda>>}
JOIN_KINDS = {<TokenType.SEMI: 'SEMI'>, <TokenType.ARRAY: 'ARRAY'>, <TokenType.INNER: 'INNER'>, <TokenType.OUTER: 'OUTER'>, <TokenType.ASOF: 'ASOF'>, <TokenType.CROSS: 'CROSS'>, <TokenType.ANY: 'ANY'>, <TokenType.ANTI: 'ANTI'>}
TABLE_ALIAS_TOKENS = {<TokenType.KEEP: 'KEEP'>, <TokenType.USMALLINT: 'USMALLINT'>, <TokenType.AGGREGATEFUNCTION: 'AGGREGATEFUNCTION'>, <TokenType.IDENTIFIER: 'IDENTIFIER'>, <TokenType.TINYINT: 'TINYINT'>, <TokenType.INT4RANGE: 'INT4RANGE'>, <TokenType.CHAR: 'CHAR'>, <TokenType.DATEMULTIRANGE: 'DATEMULTIRANGE'>, <TokenType.JSON: 'JSON'>, <TokenType.ENUM16: 'ENUM16'>, <TokenType.TIMESTAMP_MS: 'TIMESTAMP_MS'>, <TokenType.ISNULL: 'ISNULL'>, <TokenType.MEDIUMINT: 'MEDIUMINT'>, <TokenType.CURRENT_DATETIME: 'CURRENT_DATETIME'>, <TokenType.CURRENT_DATE: 'CURRENT_DATE'>, <TokenType.INET: 'INET'>, <TokenType.FIXEDSTRING: 'FIXEDSTRING'>, <TokenType.HLLSKETCH: 'HLLSKETCH'>, <TokenType.VOLATILE: 'VOLATILE'>, <TokenType.TEMPORARY: 'TEMPORARY'>, <TokenType.LONGTEXT: 'LONGTEXT'>, <TokenType.YEAR: 'YEAR'>, <TokenType.XML: 'XML'>, <TokenType.MEDIUMTEXT: 'MEDIUMTEXT'>, <TokenType.SMALLINT: 'SMALLINT'>, <TokenType.INT: 'INT'>, <TokenType.CONSTRAINT: 'CONSTRAINT'>, <TokenType.TSTZRANGE: 'TSTZRANGE'>, <TokenType.BEGIN: 'BEGIN'>, <TokenType.TSTZMULTIRANGE: 'TSTZMULTIRANGE'>, <TokenType.FLOAT: 'FLOAT'>, <TokenType.BOOLEAN: 'BOOLEAN'>, <TokenType.FUNCTION: 'FUNCTION'>, <TokenType.COMMAND: 'COMMAND'>, <TokenType.INDEX: 'INDEX'>, <TokenType.TINYBLOB: 'TINYBLOB'>, <TokenType.IPV6: 'IPV6'>, <TokenType.UPDATE: 'UPDATE'>, <TokenType.ROWVERSION: 'ROWVERSION'>, <TokenType.SIMPLEAGGREGATEFUNCTION: 'SIMPLEAGGREGATEFUNCTION'>, <TokenType.PSEUDO_TYPE: 'PSEUDO_TYPE'>, <TokenType.HSTORE: 'HSTORE'>, <TokenType.DEFAULT: 'DEFAULT'>, <TokenType.DELETE: 'DELETE'>, <TokenType.TRUE: 'TRUE'>, <TokenType.DATETIME: 'DATETIME'>, <TokenType.OVERLAPS: 'OVERLAPS'>, <TokenType.UBIGINT: 'UBIGINT'>, <TokenType.NVARCHAR: 'NVARCHAR'>, <TokenType.PARTITION: 'PARTITION'>, <TokenType.TSMULTIRANGE: 'TSMULTIRANGE'>, <TokenType.SMALLSERIAL: 'SMALLSERIAL'>, <TokenType.TIMETZ: 'TIMETZ'>, <TokenType.INT8MULTIRANGE: 'INT8MULTIRANGE'>, <TokenType.NEXT: 'NEXT'>, <TokenType.DICTIONARY: 'DICTIONARY'>, <TokenType.ROW: 'ROW'>, <TokenType.SET: 'SET'>, <TokenType.TOP: 'TOP'>, <TokenType.NULL: 'NULL'>, <TokenType.VARCHAR: 'VARCHAR'>, <TokenType.NUMMULTIRANGE: 'NUMMULTIRANGE'>, <TokenType.CURRENT_TIME: 'CURRENT_TIME'>, <TokenType.GEOGRAPHY: 'GEOGRAPHY'>, <TokenType.COMMENT: 'COMMENT'>, <TokenType.TABLE: 'TABLE'>, <TokenType.FILTER: 'FILTER'>, <TokenType.BPCHAR: 'BPCHAR'>, <TokenType.UNPIVOT: 'UNPIVOT'>, <TokenType.EXECUTE: 'EXECUTE'>, <TokenType.AUTO_INCREMENT: 'AUTO_INCREMENT'>, <TokenType.UINT: 'UINT'>, <TokenType.PRAGMA: 'PRAGMA'>, <TokenType.DATE: 'DATE'>, <TokenType.PROCEDURE: 'PROCEDURE'>, <TokenType.SEQUENCE: 'SEQUENCE'>, <TokenType.UTINYINT: 'UTINYINT'>, <TokenType.LOAD: 'LOAD'>, <TokenType.BIGDECIMAL: 'BIGDECIMAL'>, <TokenType.REFRESH: 'REFRESH'>, <TokenType.OBJECT: 'OBJECT'>, <TokenType.IPPREFIX: 'IPPREFIX'>, <TokenType.CURRENT_TIMESTAMP: 'CURRENT_TIMESTAMP'>, <TokenType.ASC: 'ASC'>, <TokenType.PERCENT: 'PERCENT'>, <TokenType.TDIGEST: 'TDIGEST'>, <TokenType.VAR: 'VAR'>, <TokenType.ALL: 'ALL'>, <TokenType.COLUMN: 'COLUMN'>, <TokenType.USERDEFINED: 'USERDEFINED'>, <TokenType.CACHE: 'CACHE'>, <TokenType.UINT256: 'UINT256'>, <TokenType.COMMIT: 'COMMIT'>, <TokenType.NCHAR: 'NCHAR'>, <TokenType.ENUM: 'ENUM'>, <TokenType.JSONB: 'JSONB'>, <TokenType.TIME: 'TIME'>, <TokenType.MEDIUMBLOB: 'MEDIUMBLOB'>, <TokenType.NUMRANGE: 'NUMRANGE'>, <TokenType.VIEW: 'VIEW'>, <TokenType.FIRST: 'FIRST'>, <TokenType.OPERATOR: 'OPERATOR'>, <TokenType.CASE: 'CASE'>, <TokenType.DATETIME64: 'DATETIME64'>, <TokenType.VARIANT: 'VARIANT'>, <TokenType.TIMESTAMPTZ: 'TIMESTAMPTZ'>, <TokenType.COPY: 'COPY'>, <TokenType.SCHEMA: 'SCHEMA'>, <TokenType.DATABASE: 'DATABASE'>, <TokenType.NAME: 'NAME'>, <TokenType.END: 'END'>, <TokenType.INTERVAL: 'INTERVAL'>, <TokenType.UNIQUEIDENTIFIER: 'UNIQUEIDENTIFIER'>, <TokenType.KILL: 'KILL'>, <TokenType.UNKNOWN: 'UNKNOWN'>, <TokenType.STORAGE_INTEGRATION: 'STORAGE_INTEGRATION'>, <TokenType.UINT128: 'UINT128'>, <TokenType.TIMESTAMPLTZ: 'TIMESTAMPLTZ'>, <TokenType.MERGE: 'MERGE'>, <TokenType.DOUBLE: 'DOUBLE'>, <TokenType.IPADDRESS: 'IPADDRESS'>, <TokenType.BINARY: 'BINARY'>, <TokenType.SOME: 'SOME'>, <TokenType.MAP: 'MAP'>, <TokenType.NESTED: 'NESTED'>, <TokenType.DESCRIBE: 'DESCRIBE'>, <TokenType.PIVOT: 'PIVOT'>, <TokenType.MONEY: 'MONEY'>, <TokenType.LONGBLOB: 'LONGBLOB'>, <TokenType.SMALLMONEY: 'SMALLMONEY'>, <TokenType.BIGSERIAL: 'BIGSERIAL'>, <TokenType.BIT: 'BIT'>, <TokenType.NULLABLE: 'NULLABLE'>, <TokenType.TIMESTAMP: 'TIMESTAMP'>, <TokenType.UMEDIUMINT: 'UMEDIUMINT'>, <TokenType.TIMESTAMPNTZ: 'TIMESTAMPNTZ'>, <TokenType.ROWS: 'ROWS'>, <TokenType.CURRENT_USER: 'CURRENT_USER'>, <TokenType.VARBINARY: 'VARBINARY'>, <TokenType.USE: 'USE'>, <TokenType.EXISTS: 'EXISTS'>, <TokenType.COLLATE: 'COLLATE'>, <TokenType.INT256: 'INT256'>, <TokenType.DESC: 'DESC'>, <TokenType.RECURSIVE: 'RECURSIVE'>, <TokenType.ORDINALITY: 'ORDINALITY'>, <TokenType.REPLACE: 'REPLACE'>, <TokenType.BIGINT: 'BIGINT'>, <TokenType.TINYTEXT: 'TINYTEXT'>, <TokenType.FALSE: 'FALSE'>, <TokenType.REFERENCES: 'REFERENCES'>, <TokenType.SERIAL: 'SERIAL'>, <TokenType.OVERWRITE: 'OVERWRITE'>, <TokenType.TSRANGE: 'TSRANGE'>, <TokenType.ENUM8: 'ENUM8'>, <TokenType.TEXT: 'TEXT'>, <TokenType.SUPER: 'SUPER'>, <TokenType.ESCAPE: 'ESCAPE'>, <TokenType.DATERANGE: 'DATERANGE'>, <TokenType.DECIMAL: 'DECIMAL'>, <TokenType.STRUCT: 'STRUCT'>, <TokenType.MODEL: 'MODEL'>, <TokenType.OBJECT_IDENTIFIER: 'OBJECT_IDENTIFIER'>, <TokenType.DIV: 'DIV'>, <TokenType.INT8RANGE: 'INT8RANGE'>, <TokenType.UDECIMAL: 'UDECIMAL'>, <TokenType.TIMESTAMP_NS: 'TIMESTAMP_NS'>, <TokenType.INT128: 'INT128'>, <TokenType.UUID: 'UUID'>, <TokenType.IS: 'IS'>, <TokenType.RANGE: 'RANGE'>, <TokenType.IPV4: 'IPV4'>, <TokenType.DATE32: 'DATE32'>, <TokenType.INT4MULTIRANGE: 'INT4MULTIRANGE'>, <TokenType.SHOW: 'SHOW'>, <TokenType.FOREIGN_KEY: 'FOREIGN_KEY'>, <TokenType.TIMESTAMP_S: 'TIMESTAMP_S'>, <TokenType.UNIQUE: 'UNIQUE'>, <TokenType.GEOMETRY: 'GEOMETRY'>, <TokenType.TRUNCATE: 'TRUNCATE'>, <TokenType.LOWCARDINALITY: 'LOWCARDINALITY'>, <TokenType.IMAGE: 'IMAGE'>}
ALIAS_TOKENS = {<TokenType.KEEP: 'KEEP'>, <TokenType.USMALLINT: 'USMALLINT'>, <TokenType.AGGREGATEFUNCTION: 'AGGREGATEFUNCTION'>, <TokenType.IDENTIFIER: 'IDENTIFIER'>, <TokenType.TINYINT: 'TINYINT'>, <TokenType.INT4RANGE: 'INT4RANGE'>, <TokenType.CHAR: 'CHAR'>, <TokenType.DATEMULTIRANGE: 'DATEMULTIRANGE'>, <TokenType.JSON: 'JSON'>, <TokenType.ENUM16: 'ENUM16'>, <TokenType.TIMESTAMP_MS: 'TIMESTAMP_MS'>, <TokenType.ISNULL: 'ISNULL'>, <TokenType.LOWCARDINALITY: 'LOWCARDINALITY'>, <TokenType.MEDIUMINT: 'MEDIUMINT'>, <TokenType.CURRENT_DATETIME: 'CURRENT_DATETIME'>, <TokenType.CURRENT_DATE: 'CURRENT_DATE'>, <TokenType.INET: 'INET'>, <TokenType.FIXEDSTRING: 'FIXEDSTRING'>, <TokenType.HLLSKETCH: 'HLLSKETCH'>, <TokenType.VOLATILE: 'VOLATILE'>, <TokenType.TEMPORARY: 'TEMPORARY'>, <TokenType.LONGTEXT: 'LONGTEXT'>, <TokenType.YEAR: 'YEAR'>, <TokenType.XML: 'XML'>, <TokenType.MEDIUMTEXT: 'MEDIUMTEXT'>, <TokenType.SMALLINT: 'SMALLINT'>, <TokenType.INT: 'INT'>, <TokenType.CONSTRAINT: 'CONSTRAINT'>, <TokenType.TSTZRANGE: 'TSTZRANGE'>, <TokenType.OFFSET: 'OFFSET'>, <TokenType.BEGIN: 'BEGIN'>, <TokenType.FINAL: 'FINAL'>, <TokenType.TSTZMULTIRANGE: 'TSTZMULTIRANGE'>, <TokenType.ARRAY: 'ARRAY'>, <TokenType.FLOAT: 'FLOAT'>, <TokenType.BOOLEAN: 'BOOLEAN'>, <TokenType.FUNCTION: 'FUNCTION'>, <TokenType.COMMAND: 'COMMAND'>, <TokenType.INDEX: 'INDEX'>, <TokenType.TINYBLOB: 'TINYBLOB'>, <TokenType.IPV6: 'IPV6'>, <TokenType.UPDATE: 'UPDATE'>, <TokenType.ROWVERSION: 'ROWVERSION'>, <TokenType.SIMPLEAGGREGATEFUNCTION: 'SIMPLEAGGREGATEFUNCTION'>, <TokenType.PSEUDO_TYPE: 'PSEUDO_TYPE'>, <TokenType.HSTORE: 'HSTORE'>, <TokenType.RIGHT: 'RIGHT'>, <TokenType.DEFAULT: 'DEFAULT'>, <TokenType.DELETE: 'DELETE'>, <TokenType.TRUE: 'TRUE'>, <TokenType.DATETIME: 'DATETIME'>, <TokenType.OVERLAPS: 'OVERLAPS'>, <TokenType.UBIGINT: 'UBIGINT'>, <TokenType.NVARCHAR: 'NVARCHAR'>, <TokenType.PARTITION: 'PARTITION'>, <TokenType.TSMULTIRANGE: 'TSMULTIRANGE'>, <TokenType.SMALLSERIAL: 'SMALLSERIAL'>, <TokenType.TIMETZ: 'TIMETZ'>, <TokenType.INT8MULTIRANGE: 'INT8MULTIRANGE'>, <TokenType.NEXT: 'NEXT'>, <TokenType.DICTIONARY: 'DICTIONARY'>, <TokenType.ROW: 'ROW'>, <TokenType.SET: 'SET'>, <TokenType.TOP: 'TOP'>, <TokenType.NULL: 'NULL'>, <TokenType.VARCHAR: 'VARCHAR'>, <TokenType.NUMMULTIRANGE: 'NUMMULTIRANGE'>, <TokenType.CURRENT_TIME: 'CURRENT_TIME'>, <TokenType.GEOGRAPHY: 'GEOGRAPHY'>, <TokenType.COMMENT: 'COMMENT'>, <TokenType.TABLE: 'TABLE'>, <TokenType.FILTER: 'FILTER'>, <TokenType.BPCHAR: 'BPCHAR'>, <TokenType.ANTI: 'ANTI'>, <TokenType.UNPIVOT: 'UNPIVOT'>, <TokenType.EXECUTE: 'EXECUTE'>, <TokenType.AUTO_INCREMENT: 'AUTO_INCREMENT'>, <TokenType.UINT: 'UINT'>, <TokenType.PRAGMA: 'PRAGMA'>, <TokenType.DATE: 'DATE'>, <TokenType.PROCEDURE: 'PROCEDURE'>, <TokenType.SEQUENCE: 'SEQUENCE'>, <TokenType.SETTINGS: 'SETTINGS'>, <TokenType.UTINYINT: 'UTINYINT'>, <TokenType.LOAD: 'LOAD'>, <TokenType.BIGDECIMAL: 'BIGDECIMAL'>, <TokenType.REFRESH: 'REFRESH'>, <TokenType.OBJECT: 'OBJECT'>, <TokenType.IPPREFIX: 'IPPREFIX'>, <TokenType.CURRENT_TIMESTAMP: 'CURRENT_TIMESTAMP'>, <TokenType.ASC: 'ASC'>, <TokenType.PERCENT: 'PERCENT'>, <TokenType.TDIGEST: 'TDIGEST'>, <TokenType.VAR: 'VAR'>, <TokenType.ALL: 'ALL'>, <TokenType.COLUMN: 'COLUMN'>, <TokenType.USERDEFINED: 'USERDEFINED'>, <TokenType.CACHE: 'CACHE'>, <TokenType.UINT256: 'UINT256'>, <TokenType.COMMIT: 'COMMIT'>, <TokenType.LEFT: 'LEFT'>, <TokenType.NCHAR: 'NCHAR'>, <TokenType.ENUM: 'ENUM'>, <TokenType.JSONB: 'JSONB'>, <TokenType.TIME: 'TIME'>, <TokenType.MEDIUMBLOB: 'MEDIUMBLOB'>, <TokenType.NUMRANGE: 'NUMRANGE'>, <TokenType.VIEW: 'VIEW'>, <TokenType.FIRST: 'FIRST'>, <TokenType.OPERATOR: 'OPERATOR'>, <TokenType.CASE: 'CASE'>, <TokenType.APPLY: 'APPLY'>, <TokenType.DATETIME64: 'DATETIME64'>, <TokenType.VARIANT: 'VARIANT'>, <TokenType.ANY: 'ANY'>, <TokenType.TIMESTAMPTZ: 'TIMESTAMPTZ'>, <TokenType.COPY: 'COPY'>, <TokenType.NATURAL: 'NATURAL'>, <TokenType.FULL: 'FULL'>, <TokenType.SCHEMA: 'SCHEMA'>, <TokenType.DATABASE: 'DATABASE'>, <TokenType.NAME: 'NAME'>, <TokenType.END: 'END'>, <TokenType.INTERVAL: 'INTERVAL'>, <TokenType.UNIQUEIDENTIFIER: 'UNIQUEIDENTIFIER'>, <TokenType.WINDOW: 'WINDOW'>, <TokenType.KILL: 'KILL'>, <TokenType.UNKNOWN: 'UNKNOWN'>, <TokenType.UINT128: 'UINT128'>, <TokenType.TIMESTAMPLTZ: 'TIMESTAMPLTZ'>, <TokenType.MERGE: 'MERGE'>, <TokenType.DOUBLE: 'DOUBLE'>, <TokenType.IPADDRESS: 'IPADDRESS'>, <TokenType.BINARY: 'BINARY'>, <TokenType.SOME: 'SOME'>, <TokenType.MAP: 'MAP'>, <TokenType.NESTED: 'NESTED'>, <TokenType.DESCRIBE: 'DESCRIBE'>, <TokenType.PIVOT: 'PIVOT'>, <TokenType.MONEY: 'MONEY'>, <TokenType.LONGBLOB: 'LONGBLOB'>, <TokenType.SMALLMONEY: 'SMALLMONEY'>, <TokenType.SEMI: 'SEMI'>, <TokenType.BIGSERIAL: 'BIGSERIAL'>, <TokenType.BIT: 'BIT'>, <TokenType.NULLABLE: 'NULLABLE'>, <TokenType.TIMESTAMP: 'TIMESTAMP'>, <TokenType.UMEDIUMINT: 'UMEDIUMINT'>, <TokenType.TIMESTAMPNTZ: 'TIMESTAMPNTZ'>, <TokenType.ROWS: 'ROWS'>, <TokenType.CURRENT_USER: 'CURRENT_USER'>, <TokenType.VARBINARY: 'VARBINARY'>, <TokenType.USE: 'USE'>, <TokenType.EXISTS: 'EXISTS'>, <TokenType.COLLATE: 'COLLATE'>, <TokenType.INT256: 'INT256'>, <TokenType.DESC: 'DESC'>, <TokenType.ASOF: 'ASOF'>, <TokenType.RECURSIVE: 'RECURSIVE'>, <TokenType.ORDINALITY: 'ORDINALITY'>, <TokenType.REPLACE: 'REPLACE'>, <TokenType.BIGINT: 'BIGINT'>, <TokenType.TINYTEXT: 'TINYTEXT'>, <TokenType.FALSE: 'FALSE'>, <TokenType.REFERENCES: 'REFERENCES'>, <TokenType.SERIAL: 'SERIAL'>, <TokenType.OVERWRITE: 'OVERWRITE'>, <TokenType.TSRANGE: 'TSRANGE'>, <TokenType.ENUM8: 'ENUM8'>, <TokenType.TEXT: 'TEXT'>, <TokenType.SUPER: 'SUPER'>, <TokenType.ESCAPE: 'ESCAPE'>, <TokenType.DATERANGE: 'DATERANGE'>, <TokenType.DECIMAL: 'DECIMAL'>, <TokenType.STRUCT: 'STRUCT'>, <TokenType.MODEL: 'MODEL'>, <TokenType.OBJECT_IDENTIFIER: 'OBJECT_IDENTIFIER'>, <TokenType.DIV: 'DIV'>, <TokenType.INT8RANGE: 'INT8RANGE'>, <TokenType.UDECIMAL: 'UDECIMAL'>, <TokenType.TIMESTAMP_NS: 'TIMESTAMP_NS'>, <TokenType.INT128: 'INT128'>, <TokenType.UUID: 'UUID'>, <TokenType.IS: 'IS'>, <TokenType.RANGE: 'RANGE'>, <TokenType.IPV4: 'IPV4'>, <TokenType.DATE32: 'DATE32'>, <TokenType.INT4MULTIRANGE: 'INT4MULTIRANGE'>, <TokenType.SHOW: 'SHOW'>, <TokenType.FOREIGN_KEY: 'FOREIGN_KEY'>, <TokenType.TIMESTAMP_S: 'TIMESTAMP_S'>, <TokenType.UNIQUE: 'UNIQUE'>, <TokenType.GEOMETRY: 'GEOMETRY'>, <TokenType.TRUNCATE: 'TRUNCATE'>, <TokenType.STORAGE_INTEGRATION: 'STORAGE_INTEGRATION'>, <TokenType.IMAGE: 'IMAGE'>}
LOG_DEFAULTS_TO_LN = True
QUERY_MODIFIER_PARSERS = {<TokenType.MATCH_RECOGNIZE: 'MATCH_RECOGNIZE'>: <function Parser.<lambda>>, <TokenType.PREWHERE: 'PREWHERE'>: <function Parser.<lambda>>, <TokenType.WHERE: 'WHERE'>: <function Parser.<lambda>>, <TokenType.GROUP_BY: 'GROUP_BY'>: <function Parser.<lambda>>, <TokenType.HAVING: 'HAVING'>: <function Parser.<lambda>>, <TokenType.QUALIFY: 'QUALIFY'>: <function Parser.<lambda>>, <TokenType.WINDOW: 'WINDOW'>: <function Parser.<lambda>>, <TokenType.ORDER_BY: 'ORDER_BY'>: <function Parser.<lambda>>, <TokenType.LIMIT: 'LIMIT'>: <function Parser.<lambda>>, <TokenType.FETCH: 'FETCH'>: <function Parser.<lambda>>, <TokenType.OFFSET: 'OFFSET'>: <function Parser.<lambda>>, <TokenType.FOR: 'FOR'>: <function Parser.<lambda>>, <TokenType.LOCK: 'LOCK'>: <function Parser.<lambda>>, <TokenType.TABLE_SAMPLE: 'TABLE_SAMPLE'>: <function Parser.<lambda>>, <TokenType.USING: 'USING'>: <function Parser.<lambda>>, <TokenType.CLUSTER_BY: 'CLUSTER_BY'>: <function Parser.<lambda>>, <TokenType.DISTRIBUTE_BY: 'DISTRIBUTE_BY'>: <function Parser.<lambda>>, <TokenType.SORT_BY: 'SORT_BY'>: <function Parser.<lambda>>, <TokenType.CONNECT_BY: 'CONNECT_BY'>: <function Parser.<lambda>>, <TokenType.START_WITH: 'START_WITH'>: <function Parser.<lambda>>, <TokenType.SETTINGS: 'SETTINGS'>: <function ClickHouse.Parser.<lambda>>, <TokenType.FORMAT: 'FORMAT'>: <function ClickHouse.Parser.<lambda>>}
CONSTRAINT_PARSERS = {'AUTOINCREMENT': <function Parser.<lambda>>, 'AUTO_INCREMENT': <function Parser.<lambda>>, 'CASESPECIFIC': <function Parser.<lambda>>, 'CHARACTER SET': <function Parser.<lambda>>, 'CHECK': <function Parser.<lambda>>, 'COLLATE': <function Parser.<lambda>>, 'COMMENT': <function Parser.<lambda>>, 'COMPRESS': <function Parser.<lambda>>, 'CLUSTERED': <function Parser.<lambda>>, 'NONCLUSTERED': <function Parser.<lambda>>, 'DEFAULT': <function Parser.<lambda>>, 'ENCODE': <function Parser.<lambda>>, 'EPHEMERAL': <function Parser.<lambda>>, 'EXCLUDE': <function Parser.<lambda>>, 'FOREIGN KEY': <function Parser.<lambda>>, 'FORMAT': <function Parser.<lambda>>, 'GENERATED': <function Parser.<lambda>>, 'IDENTITY': <function Parser.<lambda>>, 'INLINE': <function Parser.<lambda>>, 'LIKE': <function Parser.<lambda>>, 'NOT': <function Parser.<lambda>>, 'NULL': <function Parser.<lambda>>, 'ON': <function Parser.<lambda>>, 'PATH': <function Parser.<lambda>>, 'PERIOD': <function Parser.<lambda>>, 'PRIMARY KEY': <function Parser.<lambda>>, 'REFERENCES': <function Parser.<lambda>>, 'TITLE': <function Parser.<lambda>>, 'TTL': <function Parser.<lambda>>, 'UNIQUE': <function Parser.<lambda>>, 'UPPERCASE': <function Parser.<lambda>>, 'WITH': <function Parser.<lambda>>, 'INDEX': <function ClickHouse.Parser.<lambda>>, 'CODEC': <function ClickHouse.Parser.<lambda>>}
SCHEMA_UNNAMED_CONSTRAINTS = {'UNIQUE', 'PRIMARY KEY', 'PERIOD', 'CHECK', 'INDEX', 'EXCLUDE', 'LIKE', 'FOREIGN KEY'}
SHOW_TRIE: Dict = {}
SET_TRIE: Dict = {'GLOBAL': {0: True}, 'LOCAL': {0: True}, 'SESSION': {0: True}, 'TRANSACTION': {0: True}}

##### Inherited Members

sqlglot.parser.Parser
  Parser
  NO_PAREN_FUNCTIONS
  STRUCT_TYPE_TOKENS
  NESTED_TYPE_TOKENS
  ENUM_TYPE_TOKENS
  AGGREGATE_TYPE_TOKENS
  TYPE_TOKENS
  SIGNED_TO_UNSIGNED_TYPE_TOKEN
  SUBQUERY_PREDICATES
  RESERVED_TOKENS
  DB_CREATABLES
  CREATABLES
  ID_VAR_TOKENS
  INTERVAL_VARS
  COMMENT_TABLE_ALIAS_TOKENS
  UPDATE_ALIAS_TOKENS
  TRIM_TYPES
  CONJUNCTION
  EQUALITY
  COMPARISON
  BITWISE
  TERM
  FACTOR
  EXPONENT
  TIMES
  TIMESTAMPS
  SET_OPERATIONS
  JOIN_METHODS
  JOIN_SIDES
  JOIN_HINTS
  LAMBDAS
  EXPRESSION_PARSERS
  STATEMENT_PARSERS
  UNARY_PARSERS
  STRING_PARSERS
  NUMERIC_PARSERS
  PRIMARY_PARSERS
  PLACEHOLDER_PARSERS
  PROPERTY_PARSERS
  ALTER_PARSERS
  INVALID_FUNC_NAME_TOKENS
  KEY_VALUE_DEFINITIONS
  SET_PARSERS
  SHOW_PARSERS
  TYPE_LITERAL_PARSERS
  DDL_SELECT_TOKENS
  PRE_VOLATILE_TOKENS
  TRANSACTION_KIND
  TRANSACTION_CHARACTERISTICS
  CONFLICT_ACTIONS
  CREATE_SEQUENCE
  ISOLATED_LOADING_OPTIONS
  USABLES
  CAST_ACTIONS
  INSERT_ALTERNATIVES
  CLONE_KEYWORDS
  HISTORICAL_DATA_KIND
  OPCLASS_FOLLOW_KEYWORDS
  OPTYPE_FOLLOW_TOKENS
  TABLE_INDEX_HINT_TOKENS
  VIEW_ATTRIBUTES
  WINDOW_ALIAS_TOKENS
  WINDOW_BEFORE_PAREN_TOKENS
  WINDOW_SIDES
  JSON_KEY_VALUE_SEPARATOR_TOKENS
  FETCH_TOKENS
  ADD_CONSTRAINT_TOKENS
  DISTINCT_TOKENS
  NULL_TOKENS
  UNNEST_OFFSET_ALIAS_TOKENS
  SELECT_START_TOKENS
  STRICT_CAST
  PREFIXED_PIVOT_COLUMNS
  IDENTIFY_PIVOT_STRINGS
  ALTER_TABLE_ADD_REQUIRED_FOR_EACH_COLUMN
  TABLESAMPLE_CSV
  SET_REQUIRES_ASSIGNMENT_DELIMITER
  TRIM_PATTERN_FIRST
  STRING_ALIASES
  UNION_MODIFIERS
  NO_PAREN_IF_COMMANDS
  JSON_ARROWS_REQUIRE_JSON_TYPE
  VALUES_FOLLOWED_BY_PAREN
  SUPPORTS_IMPLICIT_UNNEST
  SUPPORTS_PARTITION_SELECTION
  error_level
  error_message_context
  max_errors
  dialect
  reset
  parse
  parse_into
  check_errors
  raise_error
  expression
  validate_expression
  errors
  sql

class ClickHouse.Generator(sqlglot.generator.Generator): View Source

    582    class Generator(generator.Generator):
    583        QUERY_HINTS = False
    584        STRUCT_DELIMITER = ("(", ")")
    585        NVL2_SUPPORTED = False
    586        TABLESAMPLE_REQUIRES_PARENS = False
    587        TABLESAMPLE_SIZE_IS_ROWS = False
    588        TABLESAMPLE_KEYWORDS = "SAMPLE"
    589        LAST_DAY_SUPPORTS_DATE_PART = False
    590        CAN_IMPLEMENT_ARRAY_ANY = True
    591        SUPPORTS_TO_NUMBER = False
    592
    593        STRING_TYPE_MAPPING = {
    594            exp.DataType.Type.CHAR: "String",
    595            exp.DataType.Type.LONGBLOB: "String",
    596            exp.DataType.Type.LONGTEXT: "String",
    597            exp.DataType.Type.MEDIUMBLOB: "String",
    598            exp.DataType.Type.MEDIUMTEXT: "String",
    599            exp.DataType.Type.TINYBLOB: "String",
    600            exp.DataType.Type.TINYTEXT: "String",
    601            exp.DataType.Type.TEXT: "String",
    602            exp.DataType.Type.VARBINARY: "String",
    603            exp.DataType.Type.VARCHAR: "String",
    604        }
    605
    606        SUPPORTED_JSON_PATH_PARTS = {
    607            exp.JSONPathKey,
    608            exp.JSONPathRoot,
    609            exp.JSONPathSubscript,
    610        }
    611
    612        TYPE_MAPPING = {
    613            **generator.Generator.TYPE_MAPPING,
    614            **STRING_TYPE_MAPPING,
    615            exp.DataType.Type.ARRAY: "Array",
    616            exp.DataType.Type.BIGINT: "Int64",
    617            exp.DataType.Type.DATE32: "Date32",
    618            exp.DataType.Type.DATETIME64: "DateTime64",
    619            exp.DataType.Type.DOUBLE: "Float64",
    620            exp.DataType.Type.ENUM: "Enum",
    621            exp.DataType.Type.ENUM8: "Enum8",
    622            exp.DataType.Type.ENUM16: "Enum16",
    623            exp.DataType.Type.FIXEDSTRING: "FixedString",
    624            exp.DataType.Type.FLOAT: "Float32",
    625            exp.DataType.Type.INT: "Int32",
    626            exp.DataType.Type.MEDIUMINT: "Int32",
    627            exp.DataType.Type.INT128: "Int128",
    628            exp.DataType.Type.INT256: "Int256",
    629            exp.DataType.Type.LOWCARDINALITY: "LowCardinality",
    630            exp.DataType.Type.MAP: "Map",
    631            exp.DataType.Type.NESTED: "Nested",
    632            exp.DataType.Type.NULLABLE: "Nullable",
    633            exp.DataType.Type.SMALLINT: "Int16",
    634            exp.DataType.Type.STRUCT: "Tuple",
    635            exp.DataType.Type.TINYINT: "Int8",
    636            exp.DataType.Type.UBIGINT: "UInt64",
    637            exp.DataType.Type.UINT: "UInt32",
    638            exp.DataType.Type.UINT128: "UInt128",
    639            exp.DataType.Type.UINT256: "UInt256",
    640            exp.DataType.Type.USMALLINT: "UInt16",
    641            exp.DataType.Type.UTINYINT: "UInt8",
    642            exp.DataType.Type.IPV4: "IPv4",
    643            exp.DataType.Type.IPV6: "IPv6",
    644            exp.DataType.Type.AGGREGATEFUNCTION: "AggregateFunction",
    645            exp.DataType.Type.SIMPLEAGGREGATEFUNCTION: "SimpleAggregateFunction",
    646        }
    647
    648        TRANSFORMS = {
    649            **generator.Generator.TRANSFORMS,
    650            exp.AnyValue: rename_func("any"),
    651            exp.ApproxDistinct: rename_func("uniq"),
    652            exp.ArrayFilter: lambda self, e: self.func("arrayFilter", e.expression, e.this),
    653            exp.ArraySize: rename_func("LENGTH"),
    654            exp.ArraySum: rename_func("arraySum"),
    655            exp.ArgMax: arg_max_or_min_no_count("argMax"),
    656            exp.ArgMin: arg_max_or_min_no_count("argMin"),
    657            exp.Array: inline_array_sql,
    658            exp.CastToStrType: rename_func("CAST"),
    659            exp.CountIf: rename_func("countIf"),
    660            exp.CompressColumnConstraint: lambda self,
    661            e: f"CODEC({self.expressions(e, key='this', flat=True)})",
    662            exp.ComputedColumnConstraint: lambda self,
    663            e: f"{'MATERIALIZED' if e.args.get('persisted') else 'ALIAS'} {self.sql(e, 'this')}",
    664            exp.CurrentDate: lambda self, e: self.func("CURRENT_DATE"),
    665            exp.DateAdd: date_delta_sql("DATE_ADD"),
    666            exp.DateDiff: date_delta_sql("DATE_DIFF"),
    667            exp.Explode: rename_func("arrayJoin"),
    668            exp.Final: lambda self, e: f"{self.sql(e, 'this')} FINAL",
    669            exp.IsNan: rename_func("isNaN"),
    670            exp.JSONExtract: json_extract_segments("JSONExtractString", quoted_index=False),
    671            exp.JSONExtractScalar: json_extract_segments("JSONExtractString", quoted_index=False),
    672            exp.JSONPathKey: json_path_key_only_name,
    673            exp.JSONPathRoot: lambda *_: "",
    674            exp.Map: lambda self, e: _lower_func(var_map_sql(self, e)),
    675            exp.Nullif: rename_func("nullIf"),
    676            exp.PartitionedByProperty: lambda self, e: f"PARTITION BY {self.sql(e, 'this')}",
    677            exp.Pivot: no_pivot_sql,
    678            exp.Quantile: _quantile_sql,
    679            exp.RegexpLike: lambda self, e: self.func("match", e.this, e.expression),
    680            exp.Rand: rename_func("randCanonical"),
    681            exp.Select: transforms.preprocess([transforms.eliminate_qualify]),
    682            exp.StartsWith: rename_func("startsWith"),
    683            exp.StrPosition: lambda self, e: self.func(
    684                "position", e.this, e.args.get("substr"), e.args.get("position")
    685            ),
    686            exp.TimeToStr: lambda self, e: self.func(
    687                "DATE_FORMAT", e.this, self.format_time(e), e.args.get("timezone")
    688            ),
    689            exp.VarMap: lambda self, e: _lower_func(var_map_sql(self, e)),
    690            exp.Xor: lambda self, e: self.func("xor", e.this, e.expression, *e.expressions),
    691        }
    692
    693        PROPERTIES_LOCATION = {
    694            **generator.Generator.PROPERTIES_LOCATION,
    695            exp.VolatileProperty: exp.Properties.Location.UNSUPPORTED,
    696            exp.PartitionedByProperty: exp.Properties.Location.POST_SCHEMA,
    697            exp.OnCluster: exp.Properties.Location.POST_NAME,
    698        }
    699
    700        JOIN_HINTS = False
    701        TABLE_HINTS = False
    702        EXPLICIT_UNION = True
    703        GROUPINGS_SEP = ""
    704        OUTER_UNION_MODIFIERS = False
    705
    706        # there's no list in docs, but it can be found in Clickhouse code
    707        # see `ClickHouse/src/Parsers/ParserCreate*.cpp`
    708        ON_CLUSTER_TARGETS = {
    709            "DATABASE",
    710            "TABLE",
    711            "VIEW",
    712            "DICTIONARY",
    713            "INDEX",
    714            "FUNCTION",
    715            "NAMED COLLECTION",
    716        }
    717
    718        def _jsonpathsubscript_sql(self, expression: exp.JSONPathSubscript) -> str:
    719            this = self.json_path_part(expression.this)
    720            return str(int(this) + 1) if is_int(this) else this
    721
    722        def likeproperty_sql(self, expression: exp.LikeProperty) -> str:
    723            return f"AS {self.sql(expression, 'this')}"
    724
    725        def _any_to_has(
    726            self,
    727            expression: exp.EQ | exp.NEQ,
    728            default: t.Callable[[t.Any], str],
    729            prefix: str = "",
    730        ) -> str:
    731            if isinstance(expression.left, exp.Any):
    732                arr = expression.left
    733                this = expression.right
    734            elif isinstance(expression.right, exp.Any):
    735                arr = expression.right
    736                this = expression.left
    737            else:
    738                return default(expression)
    739
    740            return prefix + self.func("has", arr.this.unnest(), this)
    741
    742        def eq_sql(self, expression: exp.EQ) -> str:
    743            return self._any_to_has(expression, super().eq_sql)
    744
    745        def neq_sql(self, expression: exp.NEQ) -> str:
    746            return self._any_to_has(expression, super().neq_sql, "NOT ")
    747
    748        def regexpilike_sql(self, expression: exp.RegexpILike) -> str:
    749            # Manually add a flag to make the search case-insensitive
    750            regex = self.func("CONCAT", "'(?i)'", expression.expression)
    751            return self.func("match", expression.this, regex)
    752
    753        def datatype_sql(self, expression: exp.DataType) -> str:
    754            # String is the standard ClickHouse type, every other variant is just an alias.
    755            # Additionally, any supplied length parameter will be ignored.
    756            #
    757            # https://clickhouse.com/docs/en/sql-reference/data-types/string
    758            if expression.this in self.STRING_TYPE_MAPPING:
    759                return "String"
    760
    761            return super().datatype_sql(expression)
    762
    763        def cte_sql(self, expression: exp.CTE) -> str:
    764            if expression.args.get("scalar"):
    765                this = self.sql(expression, "this")
    766                alias = self.sql(expression, "alias")
    767                return f"{this} AS {alias}"
    768
    769            return super().cte_sql(expression)
    770
    771        def after_limit_modifiers(self, expression: exp.Expression) -> t.List[str]:
    772            return super().after_limit_modifiers(expression) + [
    773                (
    774                    self.seg("SETTINGS ") + self.expressions(expression, key="settings", flat=True)
    775                    if expression.args.get("settings")
    776                    else ""
    777                ),
    778                (
    779                    self.seg("FORMAT ") + self.sql(expression, "format")
    780                    if expression.args.get("format")
    781                    else ""
    782                ),
    783            ]
    784
    785        def parameterizedagg_sql(self, expression: exp.ParameterizedAgg) -> str:
    786            params = self.expressions(expression, key="params", flat=True)
    787            return self.func(expression.name, *expression.expressions) + f"({params})"
    788
    789        def anonymousaggfunc_sql(self, expression: exp.AnonymousAggFunc) -> str:
    790            return self.func(expression.name, *expression.expressions)
    791
    792        def combinedaggfunc_sql(self, expression: exp.CombinedAggFunc) -> str:
    793            return self.anonymousaggfunc_sql(expression)
    794
    795        def combinedparameterizedagg_sql(self, expression: exp.CombinedParameterizedAgg) -> str:
    796            return self.parameterizedagg_sql(expression)
    797
    798        def placeholder_sql(self, expression: exp.Placeholder) -> str:
    799            return f"{{{expression.name}: {self.sql(expression, 'kind')}}}"
    800
    801        def oncluster_sql(self, expression: exp.OnCluster) -> str:
    802            return f"ON CLUSTER {self.sql(expression, 'this')}"
    803
    804        def createable_sql(self, expression: exp.Create, locations: t.DefaultDict) -> str:
    805            if expression.kind in self.ON_CLUSTER_TARGETS and locations.get(
    806                exp.Properties.Location.POST_NAME
    807            ):
    808                this_name = self.sql(expression.this, "this")
    809                this_properties = " ".join(
    810                    [self.sql(prop) for prop in locations[exp.Properties.Location.POST_NAME]]
    811                )
    812                this_schema = self.schema_columns_sql(expression.this)
    813                return f"{this_name}{self.sep()}{this_properties}{self.sep()}{this_schema}"
    814
    815            return super().createable_sql(expression, locations)
    816
    817        def prewhere_sql(self, expression: exp.PreWhere) -> str:
    818            this = self.indent(self.sql(expression, "this"))
    819            return f"{self.seg('PREWHERE')}{self.sep()}{this}"
    820
    821        def indexcolumnconstraint_sql(self, expression: exp.IndexColumnConstraint) -> str:
    822            this = self.sql(expression, "this")
    823            this = f" {this}" if this else ""
    824            expr = self.sql(expression, "expression")
    825            expr = f" {expr}" if expr else ""
    826            index_type = self.sql(expression, "index_type")
    827            index_type = f" TYPE {index_type}" if index_type else ""
    828            granularity = self.sql(expression, "granularity")
    829            granularity = f" GRANULARITY {granularity}" if granularity else ""
    830
    831            return f"INDEX{this}{expr}{index_type}{granularity}"

Generator converts a given syntax tree to the corresponding SQL string.

###### Arguments:

- pretty: Whether to format the produced SQL string. Default: False.
- identify: Determines when an identifier should be quoted. Possible values are: False (default): Never quote, except in cases where it's mandatory by the dialect. True or 'always': Always quote. 'safe': Only quote identifiers that are case insensitive.
- normalize: Whether to normalize identifiers to lowercase. Default: False.
- pad: The pad size in a formatted string. For example, this affects the indentation of a projection in a query, relative to its nesting level. Default: 2.
- indent: The indentation size in a formatted string. For example, this affects the indentation of subqueries and filters under a `WHERE` clause. Default: 2.
- normalize_functions: How to normalize function names. Possible values are: "upper" or True (default): Convert names to uppercase. "lower": Convert names to lowercase. False: Disables function name normalization.
- unsupported_level: Determines the generator's behavior when it encounters unsupported expressions. Default ErrorLevel.WARN.
- max_unsupported: Maximum number of unsupported messages to include in a raised UnsupportedError. This is only relevant if unsupported_level is ErrorLevel.RAISE. Default: 3
- leading_comma: Whether the comma is leading or trailing in select expressions. This is only relevant when generating in pretty mode. Default: False
- max_text_width: The max number of characters in a segment before creating new lines in pretty mode. The default is on the smaller end because the length only represents a segment and not the true line length. Default: 80
- comments: Whether to preserve comments in the output SQL code. Default: True

QUERY_HINTS = False
STRUCT_DELIMITER = ('(', ')')
NVL2_SUPPORTED = False
TABLESAMPLE_REQUIRES_PARENS = False
TABLESAMPLE_SIZE_IS_ROWS = False
TABLESAMPLE_KEYWORDS = 'SAMPLE'
LAST_DAY_SUPPORTS_DATE_PART = False
CAN_IMPLEMENT_ARRAY_ANY = True
SUPPORTS_TO_NUMBER = False
STRING_TYPE_MAPPING = {<Type.CHAR: 'CHAR'>: 'String', <Type.LONGBLOB: 'LONGBLOB'>: 'String', <Type.LONGTEXT: 'LONGTEXT'>: 'String', <Type.MEDIUMBLOB: 'MEDIUMBLOB'>: 'String', <Type.MEDIUMTEXT: 'MEDIUMTEXT'>: 'String', <Type.TINYBLOB: 'TINYBLOB'>: 'String', <Type.TINYTEXT: 'TINYTEXT'>: 'String', <Type.TEXT: 'TEXT'>: 'String', <Type.VARBINARY: 'VARBINARY'>: 'String', <Type.VARCHAR: 'VARCHAR'>: 'String'}
SUPPORTED_JSON_PATH_PARTS = {<class 'sqlglot.expressions.JSONPathRoot'>, <class 'sqlglot.expressions.JSONPathSubscript'>, <class 'sqlglot.expressions.JSONPathKey'>}
TYPE_MAPPING = {<Type.NCHAR: 'NCHAR'>: 'CHAR', <Type.NVARCHAR: 'NVARCHAR'>: 'VARCHAR', <Type.MEDIUMTEXT: 'MEDIUMTEXT'>: 'String', <Type.LONGTEXT: 'LONGTEXT'>: 'String', <Type.TINYTEXT: 'TINYTEXT'>: 'String', <Type.MEDIUMBLOB: 'MEDIUMBLOB'>: 'String', <Type.LONGBLOB: 'LONGBLOB'>: 'String', <Type.TINYBLOB: 'TINYBLOB'>: 'String', <Type.INET: 'INET'>: 'INET', <Type.ROWVERSION: 'ROWVERSION'>: 'VARBINARY', <Type.CHAR: 'CHAR'>: 'String', <Type.TEXT: 'TEXT'>: 'String', <Type.VARBINARY: 'VARBINARY'>: 'String', <Type.VARCHAR: 'VARCHAR'>: 'String', <Type.ARRAY: 'ARRAY'>: 'Array', <Type.BIGINT: 'BIGINT'>: 'Int64', <Type.DATE32: 'DATE32'>: 'Date32', <Type.DATETIME64: 'DATETIME64'>: 'DateTime64', <Type.DOUBLE: 'DOUBLE'>: 'Float64', <Type.ENUM: 'ENUM'>: 'Enum', <Type.ENUM8: 'ENUM8'>: 'Enum8', <Type.ENUM16: 'ENUM16'>: 'Enum16', <Type.FIXEDSTRING: 'FIXEDSTRING'>: 'FixedString', <Type.FLOAT: 'FLOAT'>: 'Float32', <Type.INT: 'INT'>: 'Int32', <Type.MEDIUMINT: 'MEDIUMINT'>: 'Int32', <Type.INT128: 'INT128'>: 'Int128', <Type.INT256: 'INT256'>: 'Int256', <Type.LOWCARDINALITY: 'LOWCARDINALITY'>: 'LowCardinality', <Type.MAP: 'MAP'>: 'Map', <Type.NESTED: 'NESTED'>: 'Nested', <Type.NULLABLE: 'NULLABLE'>: 'Nullable', <Type.SMALLINT: 'SMALLINT'>: 'Int16', <Type.STRUCT: 'STRUCT'>: 'Tuple', <Type.TINYINT: 'TINYINT'>: 'Int8', <Type.UBIGINT: 'UBIGINT'>: 'UInt64', <Type.UINT: 'UINT'>: 'UInt32', <Type.UINT128: 'UINT128'>: 'UInt128', <Type.UINT256: 'UINT256'>: 'UInt256', <Type.USMALLINT: 'USMALLINT'>: 'UInt16', <Type.UTINYINT: 'UTINYINT'>: 'UInt8', <Type.IPV4: 'IPV4'>: 'IPv4', <Type.IPV6: 'IPV6'>: 'IPv6', <Type.AGGREGATEFUNCTION: 'AGGREGATEFUNCTION'>: 'AggregateFunction', <Type.SIMPLEAGGREGATEFUNCTION: 'SIMPLEAGGREGATEFUNCTION'>: 'SimpleAggregateFunction'}
TRANSFORMS = {<class 'sqlglot.expressions.JSONPathKey'>: <function json_path_key_only_name>, <class 'sqlglot.expressions.JSONPathRoot'>: <function ClickHouse.Generator.<lambda>>, <class 'sqlglot.expressions.JSONPathSubscript'>: <function <lambda>>, <class 'sqlglot.expressions.AutoRefreshProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.BackupProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.CaseSpecificColumnConstraint'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.CharacterSetColumnConstraint'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.CharacterSetProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.ClusteredColumnConstraint'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.CollateColumnConstraint'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.CommentColumnConstraint'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.CopyGrantsProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.DateFormatColumnConstraint'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.DefaultColumnConstraint'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.EncodeColumnConstraint'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.EphemeralColumnConstraint'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.ExcludeColumnConstraint'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.ExecuteAsProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.ExternalProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.GlobalProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.HeapProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.IcebergProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.InheritsProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.InlineLengthColumnConstraint'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.InputModelProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.IntervalSpan'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.JSONExtract'>: <function json_extract_segments.<locals>._json_extract_segments>, <class 'sqlglot.expressions.JSONExtractScalar'>: <function json_extract_segments.<locals>._json_extract_segments>, <class 'sqlglot.expressions.LanguageProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.LocationProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.LogProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.MaterializedProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.NonClusteredColumnConstraint'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.NoPrimaryIndexProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.NotForReplicationColumnConstraint'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.OnCommitProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.OnProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.OnUpdateColumnConstraint'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.OutputModelProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.PathColumnConstraint'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.RemoteWithConnectionModelProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.ReturnsProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.SampleProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.SetConfigProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.SetProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.SettingsProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.SharingProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.SqlReadWriteProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.SqlSecurityProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.StabilityProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.TemporaryProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.TitleColumnConstraint'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.Timestamp'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.ToMap'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.ToTableProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.TransformModelProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.TransientProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.UppercaseColumnConstraint'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.UnloggedProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.VarMap'>: <function ClickHouse.Generator.<lambda>>, <class 'sqlglot.expressions.ViewAttributeProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.VolatileProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.WithJournalTableProperty'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.WithOperator'>: <function Generator.<lambda>>, <class 'sqlglot.expressions.AnyValue'>: <function rename_func.<locals>.<lambda>>, <class 'sqlglot.expressions.ApproxDistinct'>: <function rename_func.<locals>.<lambda>>, <class 'sqlglot.expressions.ArrayFilter'>: <function ClickHouse.Generator.<lambda>>, <class 'sqlglot.expressions.ArraySize'>: <function rename_func.<locals>.<lambda>>, <class 'sqlglot.expressions.ArraySum'>: <function rename_func.<locals>.<lambda>>, <class 'sqlglot.expressions.ArgMax'>: <function arg_max_or_min_no_count.<locals>._arg_max_or_min_sql>, <class 'sqlglot.expressions.ArgMin'>: <function arg_max_or_min_no_count.<locals>._arg_max_or_min_sql>, <class 'sqlglot.expressions.Array'>: <function inline_array_sql>, <class 'sqlglot.expressions.CastToStrType'>: <function rename_func.<locals>.<lambda>>, <class 'sqlglot.expressions.CountIf'>: <function rename_func.<locals>.<lambda>>, <class 'sqlglot.expressions.CompressColumnConstraint'>: <function ClickHouse.Generator.<lambda>>, <class 'sqlglot.expressions.ComputedColumnConstraint'>: <function ClickHouse.Generator.<lambda>>, <class 'sqlglot.expressions.CurrentDate'>: <function ClickHouse.Generator.<lambda>>, <class 'sqlglot.expressions.DateAdd'>: <function date_delta_sql.<locals>._delta_sql>, <class 'sqlglot.expressions.DateDiff'>: <function date_delta_sql.<locals>._delta_sql>, <class 'sqlglot.expressions.Explode'>: <function rename_func.<locals>.<lambda>>, <class 'sqlglot.expressions.Final'>: <function ClickHouse.Generator.<lambda>>, <class 'sqlglot.expressions.IsNan'>: <function rename_func.<locals>.<lambda>>, <class 'sqlglot.expressions.Map'>: <function ClickHouse.Generator.<lambda>>, <class 'sqlglot.expressions.Nullif'>: <function rename_func.<locals>.<lambda>>, <class 'sqlglot.expressions.PartitionedByProperty'>: <function ClickHouse.Generator.<lambda>>, <class 'sqlglot.expressions.Pivot'>: <function no_pivot_sql>, <class 'sqlglot.expressions.Quantile'>: <function _quantile_sql>, <class 'sqlglot.expressions.RegexpLike'>: <function ClickHouse.Generator.<lambda>>, <class 'sqlglot.expressions.Rand'>: <function rename_func.<locals>.<lambda>>, <class 'sqlglot.expressions.Select'>: <function preprocess.<locals>._to_sql>, <class 'sqlglot.expressions.StartsWith'>: <function rename_func.<locals>.<lambda>>, <class 'sqlglot.expressions.StrPosition'>: <function ClickHouse.Generator.<lambda>>, <class 'sqlglot.expressions.TimeToStr'>: <function ClickHouse.Generator.<lambda>>, <class 'sqlglot.expressions.Xor'>: <function ClickHouse.Generator.<lambda>>}
PROPERTIES_LOCATION = {<class 'sqlglot.expressions.AlgorithmProperty'>: <Location.POST_CREATE: 'POST_CREATE'>, <class 'sqlglot.expressions.AutoIncrementProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.AutoRefreshProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.BackupProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.BlockCompressionProperty'>: <Location.POST_NAME: 'POST_NAME'>, <class 'sqlglot.expressions.CharacterSetProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.ChecksumProperty'>: <Location.POST_NAME: 'POST_NAME'>, <class 'sqlglot.expressions.CollateProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.CopyGrantsProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.Cluster'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.ClusteredByProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.DataBlocksizeProperty'>: <Location.POST_NAME: 'POST_NAME'>, <class 'sqlglot.expressions.DefinerProperty'>: <Location.POST_CREATE: 'POST_CREATE'>, <class 'sqlglot.expressions.DictRange'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.DictProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.DistKeyProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.DistStyleProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.EngineProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.ExecuteAsProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.ExternalProperty'>: <Location.POST_CREATE: 'POST_CREATE'>, <class 'sqlglot.expressions.FallbackProperty'>: <Location.POST_NAME: 'POST_NAME'>, <class 'sqlglot.expressions.FileFormatProperty'>: <Location.POST_WITH: 'POST_WITH'>, <class 'sqlglot.expressions.FreespaceProperty'>: <Location.POST_NAME: 'POST_NAME'>, <class 'sqlglot.expressions.GlobalProperty'>: <Location.POST_CREATE: 'POST_CREATE'>, <class 'sqlglot.expressions.HeapProperty'>: <Location.POST_WITH: 'POST_WITH'>, <class 'sqlglot.expressions.InheritsProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.IcebergProperty'>: <Location.POST_CREATE: 'POST_CREATE'>, <class 'sqlglot.expressions.InputModelProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.IsolatedLoadingProperty'>: <Location.POST_NAME: 'POST_NAME'>, <class 'sqlglot.expressions.JournalProperty'>: <Location.POST_NAME: 'POST_NAME'>, <class 'sqlglot.expressions.LanguageProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.LikeProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.LocationProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.LockProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.LockingProperty'>: <Location.POST_ALIAS: 'POST_ALIAS'>, <class 'sqlglot.expressions.LogProperty'>: <Location.POST_NAME: 'POST_NAME'>, <class 'sqlglot.expressions.MaterializedProperty'>: <Location.POST_CREATE: 'POST_CREATE'>, <class 'sqlglot.expressions.MergeBlockRatioProperty'>: <Location.POST_NAME: 'POST_NAME'>, <class 'sqlglot.expressions.NoPrimaryIndexProperty'>: <Location.POST_EXPRESSION: 'POST_EXPRESSION'>, <class 'sqlglot.expressions.OnProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.OnCommitProperty'>: <Location.POST_EXPRESSION: 'POST_EXPRESSION'>, <class 'sqlglot.expressions.Order'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.OutputModelProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.PartitionedByProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.PartitionedOfProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.PrimaryKey'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.Property'>: <Location.POST_WITH: 'POST_WITH'>, <class 'sqlglot.expressions.RemoteWithConnectionModelProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.ReturnsProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.RowFormatProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.RowFormatDelimitedProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.RowFormatSerdeProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.SampleProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.SchemaCommentProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.SerdeProperties'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.Set'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.SettingsProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.SetProperty'>: <Location.POST_CREATE: 'POST_CREATE'>, <class 'sqlglot.expressions.SetConfigProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.SharingProperty'>: <Location.POST_EXPRESSION: 'POST_EXPRESSION'>, <class 'sqlglot.expressions.SequenceProperties'>: <Location.POST_EXPRESSION: 'POST_EXPRESSION'>, <class 'sqlglot.expressions.SortKeyProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.SqlReadWriteProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.SqlSecurityProperty'>: <Location.POST_CREATE: 'POST_CREATE'>, <class 'sqlglot.expressions.StabilityProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.TemporaryProperty'>: <Location.POST_CREATE: 'POST_CREATE'>, <class 'sqlglot.expressions.ToTableProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.TransientProperty'>: <Location.POST_CREATE: 'POST_CREATE'>, <class 'sqlglot.expressions.TransformModelProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.MergeTreeTTL'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.UnloggedProperty'>: <Location.POST_CREATE: 'POST_CREATE'>, <class 'sqlglot.expressions.ViewAttributeProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.VolatileProperty'>: <Location.UNSUPPORTED: 'UNSUPPORTED'>, <class 'sqlglot.expressions.WithDataProperty'>: <Location.POST_EXPRESSION: 'POST_EXPRESSION'>, <class 'sqlglot.expressions.WithJournalTableProperty'>: <Location.POST_NAME: 'POST_NAME'>, <class 'sqlglot.expressions.WithSystemVersioningProperty'>: <Location.POST_SCHEMA: 'POST_SCHEMA'>, <class 'sqlglot.expressions.OnCluster'>: <Location.POST_NAME: 'POST_NAME'>}
JOIN_HINTS = False
TABLE_HINTS = False
EXPLICIT_UNION = True
GROUPINGS_SEP = ''
OUTER_UNION_MODIFIERS = False
ON_CLUSTER_TARGETS = {'NAMED COLLECTION', 'DATABASE', 'FUNCTION', 'TABLE', 'INDEX', 'VIEW', 'DICTIONARY'}
def likeproperty_sql(self, expression: sqlglot.expressions.LikeProperty) -> str: View Source

    722        def likeproperty_sql(self, expression: exp.LikeProperty) -> str:
    723            return f"AS {self.sql(expression, 'this')}"

def eq_sql(self, expression: sqlglot.expressions.EQ) -> str: View Source

    742        def eq_sql(self, expression: exp.EQ) -> str:
    743            return self._any_to_has(expression, super().eq_sql)

def neq_sql(self, expression: sqlglot.expressions.NEQ) -> str: View Source

    745        def neq_sql(self, expression: exp.NEQ) -> str:
    746            return self._any_to_has(expression, super().neq_sql, "NOT ")

def regexpilike_sql(self, expression: sqlglot.expressions.RegexpILike) -> str: View Source

    748        def regexpilike_sql(self, expression: exp.RegexpILike) -> str:
    749            # Manually add a flag to make the search case-insensitive
    750            regex = self.func("CONCAT", "'(?i)'", expression.expression)
    751            return self.func("match", expression.this, regex)

def datatype_sql(self, expression: sqlglot.expressions.DataType) -> str: View Source

    753        def datatype_sql(self, expression: exp.DataType) -> str:
    754            # String is the standard ClickHouse type, every other variant is just an alias.
    755            # Additionally, any supplied length parameter will be ignored.
    756            #
    757            # https://clickhouse.com/docs/en/sql-reference/data-types/string
    758            if expression.this in self.STRING_TYPE_MAPPING:
    759                return "String"
    760
    761            return super().datatype_sql(expression)

def cte_sql(self, expression: sqlglot.expressions.CTE) -> str: View Source

    763        def cte_sql(self, expression: exp.CTE) -> str:
    764            if expression.args.get("scalar"):
    765                this = self.sql(expression, "this")
    766                alias = self.sql(expression, "alias")
    767                return f"{this} AS {alias}"
    768
    769            return super().cte_sql(expression)

def after_limit_modifiers(self, expression: sqlglot.expressions.Expression) -> List[str]: View Source

    771        def after_limit_modifiers(self, expression: exp.Expression) -> t.List[str]:
    772            return super().after_limit_modifiers(expression) + [
    773                (
    774                    self.seg("SETTINGS ") + self.expressions(expression, key="settings", flat=True)
    775                    if expression.args.get("settings")
    776                    else ""
    777                ),
    778                (
    779                    self.seg("FORMAT ") + self.sql(expression, "format")
    780                    if expression.args.get("format")
    781                    else ""
    782                ),
    783            ]

def parameterizedagg_sql(self, expression: sqlglot.expressions.ParameterizedAgg) -> str: View Source

    785        def parameterizedagg_sql(self, expression: exp.ParameterizedAgg) -> str:
    786            params = self.expressions(expression, key="params", flat=True)
    787            return self.func(expression.name, *expression.expressions) + f"({params})"

def anonymousaggfunc_sql(self, expression: sqlglot.expressions.AnonymousAggFunc) -> str: View Source

    789        def anonymousaggfunc_sql(self, expression: exp.AnonymousAggFunc) -> str:
    790            return self.func(expression.name, *expression.expressions)

def combinedaggfunc_sql(self, expression: sqlglot.expressions.CombinedAggFunc) -> str: View Source

    792        def combinedaggfunc_sql(self, expression: exp.CombinedAggFunc) -> str:
    793            return self.anonymousaggfunc_sql(expression)

def combinedparameterizedagg_sql(self, expression: sqlglot.expressions.CombinedParameterizedAgg) -> str: View Source

    795        def combinedparameterizedagg_sql(self, expression: exp.CombinedParameterizedAgg) -> str:
    796            return self.parameterizedagg_sql(expression)

def placeholder_sql(self, expression: sqlglot.expressions.Placeholder) -> str: View Source

    798        def placeholder_sql(self, expression: exp.Placeholder) -> str:
    799            return f"{{{expression.name}: {self.sql(expression, 'kind')}}}"

def oncluster_sql(self, expression: sqlglot.expressions.OnCluster) -> str: View Source

    801        def oncluster_sql(self, expression: exp.OnCluster) -> str:
    802            return f"ON CLUSTER {self.sql(expression, 'this')}"

def createable_sql( self, expression: sqlglot.expressions.Create, locations: DefaultDict) -> str: View Source

    804        def createable_sql(self, expression: exp.Create, locations: t.DefaultDict) -> str:
    805            if expression.kind in self.ON_CLUSTER_TARGETS and locations.get(
    806                exp.Properties.Location.POST_NAME
    807            ):
    808                this_name = self.sql(expression.this, "this")
    809                this_properties = " ".join(
    810                    [self.sql(prop) for prop in locations[exp.Properties.Location.POST_NAME]]
    811                )
    812                this_schema = self.schema_columns_sql(expression.this)
    813                return f"{this_name}{self.sep()}{this_properties}{self.sep()}{this_schema}"
    814
    815            return super().createable_sql(expression, locations)

def prewhere_sql(self, expression: sqlglot.expressions.PreWhere) -> str: View Source

    817        def prewhere_sql(self, expression: exp.PreWhere) -> str:
    818            this = self.indent(self.sql(expression, "this"))
    819            return f"{self.seg('PREWHERE')}{self.sep()}{this}"

def indexcolumnconstraint_sql(self, expression: sqlglot.expressions.IndexColumnConstraint) -> str: View Source

    821        def indexcolumnconstraint_sql(self, expression: exp.IndexColumnConstraint) -> str:
    822            this = self.sql(expression, "this")
    823            this = f" {this}" if this else ""
    824            expr = self.sql(expression, "expression")
    825            expr = f" {expr}" if expr else ""
    826            index_type = self.sql(expression, "index_type")
    827            index_type = f" TYPE {index_type}" if index_type else ""
    828            granularity = self.sql(expression, "granularity")
    829            granularity = f" GRANULARITY {granularity}" if granularity else ""
    830
    831            return f"INDEX{this}{expr}{index_type}{granularity}"

SELECT_KINDS: Tuple[str, ...] = ()
TRY_SUPPORTED = False
AFTER_HAVING_MODIFIER_TRANSFORMS = {'qualify': <function Generator.<lambda>>, 'windows': <function Generator.<lambda>>}

##### Inherited Members

sqlglot.generator.Generator
  Generator
  NULL_ORDERING_SUPPORTED
  IGNORE_NULLS_IN_FUNC
  LOCKING_READS_SUPPORTED
  WRAP_DERIVED_VALUES
  CREATE_FUNCTION_RETURN_AS
  MATCHED_BY_SOURCE
  SINGLE_STRING_INTERVAL
  INTERVAL_ALLOWS_PLURAL_FORM
  LIMIT_FETCH
  LIMIT_ONLY_LITERALS
  RENAME_TABLE_WITH_DB
  INDEX_ON
  QUERY_HINT_SEP
  IS_BOOL_ALLOWED
  DUPLICATE_KEY_UPDATE_WITH_SET
  LIMIT_IS_TOP
  RETURNING_END
  COLUMN_JOIN_MARKS_SUPPORTED
  EXTRACT_ALLOWS_QUOTES
  TZ_TO_WITH_TIME_ZONE
  VALUES_AS_TABLE
  ALTER_TABLE_INCLUDE_COLUMN_KEYWORD
  UNNEST_WITH_ORDINALITY
  AGGREGATE_FILTER_SUPPORTED
  SEMI_ANTI_JOIN_WITH_SIDE
  COMPUTED_COLUMN_WITH_TYPE
  SUPPORTS_TABLE_COPY
  TABLESAMPLE_WITH_METHOD
  TABLESAMPLE_SEED_KEYWORD
  COLLATE_IS_FUNC
  DATA_TYPE_SPECIFIERS_ALLOWED
  ENSURE_BOOLS
  CTE_RECURSIVE_KEYWORD_REQUIRED
  SUPPORTS_SINGLE_ARG_CONCAT
  SUPPORTS_TABLE_ALIAS_COLUMNS
  UNPIVOT_ALIASES_ARE_IDENTIFIERS
  JSON_KEY_VALUE_PAIR_SEP
  INSERT_OVERWRITE
  SUPPORTS_SELECT_INTO
  SUPPORTS_UNLOGGED_TABLES
  SUPPORTS_CREATE_TABLE_LIKE
  LIKE_PROPERTY_INSIDE_SCHEMA
  MULTI_ARG_DISTINCT
  JSON_TYPE_REQUIRED_FOR_EXTRACTION
  JSON_PATH_BRACKETED_KEY_SUPPORTED
  JSON_PATH_SINGLE_QUOTE_ESCAPE
  COPY_PARAMS_ARE_WRAPPED
  COPY_PARAMS_EQ_REQUIRED
  COPY_HAS_INTO_KEYWORD
  STAR_MAPPING
  TIME_PART_SINGULARS
  TOKEN_MAPPING
  PARAMETER_TOKEN
  NAMED_PLACEHOLDER_TOKEN
  RESERVED_KEYWORDS
  WITH_SEPARATED_COMMENTS
  EXCLUDE_COMMENTS
  UNWRAPPED_INTERVAL_VALUES
  PARAMETERIZABLE_TEXT_TYPES
  EXPRESSIONS_WITHOUT_NESTED_CTES
  SENTINEL_LINE_BREAK
  pretty
  identify
  normalize
  pad
  unsupported_level
  max_unsupported
  leading_comma
  max_text_width
  comments
  dialect
  normalize_functions
  unsupported_messages
  generate
  preprocess
  unsupported
  sep
  seg
  pad_comment
  maybe_comment
  wrap
  no_identify
  normalize_func
  indent
  sql
  uncache_sql
  cache_sql
  characterset_sql
  column_parts
  column_sql
  columnposition_sql
  columndef_sql
  columnconstraint_sql
  computedcolumnconstraint_sql
  autoincrementcolumnconstraint_sql
  compresscolumnconstraint_sql
  generatedasidentitycolumnconstraint_sql
  generatedasrowcolumnconstraint_sql
  periodforsystemtimeconstraint_sql
  notnullcolumnconstraint_sql
  transformcolumnconstraint_sql
  primarykeycolumnconstraint_sql
  uniquecolumnconstraint_sql
  create_sql
  sequenceproperties_sql
  clone_sql
  describe_sql
  heredoc_sql
  prepend_ctes
  with_sql
  tablealias_sql
  bitstring_sql
  hexstring_sql
  bytestring_sql
  unicodestring_sql
  rawstring_sql
  datatypeparam_sql
  directory_sql
  delete_sql
  drop_sql
  except_sql
  except_op
  fetch_sql
  filter_sql
  hint_sql
  indexparameters_sql
  index_sql
  identifier_sql
  inputoutputformat_sql
  national_sql
  partition_sql
  properties_sql
  root_properties
  properties
  with_properties
  locate_properties
  property_name
  property_sql
  fallbackproperty_sql
  journalproperty_sql
  freespaceproperty_sql
  checksumproperty_sql
  mergeblockratioproperty_sql
  datablocksizeproperty_sql
  blockcompressionproperty_sql
  isolatedloadingproperty_sql
  partitionboundspec_sql
  partitionedofproperty_sql
  lockingproperty_sql
  withdataproperty_sql
  withsystemversioningproperty_sql
  insert_sql
  intersect_sql
  intersect_op
  introducer_sql
  kill_sql
  pseudotype_sql
  objectidentifier_sql
  onconflict_sql
  returning_sql
  rowformatdelimitedproperty_sql
  withtablehint_sql
  indextablehint_sql
  historicaldata_sql
  table_parts
  table_sql
  tablesample_sql
  pivot_sql
  version_sql
  tuple_sql
  update_sql
  values_sql
  var_sql
  into_sql
  from_sql
  group_sql
  having_sql
  connect_sql
  prior_sql
  join_sql
  lambda_sql
  lateral_op
  lateral_sql
  limit_sql
  offset_sql
  setitem_sql
  set_sql
  pragma_sql
  lock_sql
  literal_sql
  escape_str
  loaddata_sql
  null_sql
  boolean_sql
  order_sql
  withfill_sql
  cluster_sql
  distribute_sql
  sort_sql
  ordered_sql
  matchrecognizemeasure_sql
  matchrecognize_sql
  query_modifiers
  queryoption_sql
  offset_limit_modifiers
  select_sql
  schema_sql
  schema_columns_sql
  star_sql
  parameter_sql
  sessionparameter_sql
  subquery_sql
  qualify_sql
  set_operations
  union_sql
  union_op
  unnest_sql
  where_sql
  window_sql
  partition_by_sql
  windowspec_sql
  withingroup_sql
  between_sql
  bracket_offset_expressions
  bracket_sql
  all_sql
  any_sql
  exists_sql
  case_sql
  constraint_sql
  nextvaluefor_sql
  extract_sql
  trim_sql
  convert_concat_args
  concat_sql
  concatws_sql
  check_sql
  foreignkey_sql
  primarykey_sql
  if_sql
  matchagainst_sql
  jsonkeyvalue_sql
  jsonpath_sql
  json_path_part
  formatjson_sql
  jsonobject_sql
  jsonobjectagg_sql
  jsonarray_sql
  jsonarrayagg_sql
  jsoncolumndef_sql
  jsonschema_sql
  jsontable_sql
  openjsoncolumndef_sql
  openjson_sql
  in_sql
  in_unnest_op
  interval_sql
  return_sql
  reference_sql
  anonymous_sql
  paren_sql
  neg_sql
  not_sql
  alias_sql
  pivotalias_sql
  aliases_sql
  atindex_sql
  attimezone_sql
  fromtimezone_sql
  add_sql
  and_sql
  or_sql
  xor_sql
  connector_sql
  bitwiseand_sql
  bitwiseleftshift_sql
  bitwisenot_sql
  bitwiseor_sql
  bitwiserightshift_sql
  bitwisexor_sql
  cast_sql
  currentdate_sql
  currenttimestamp_sql
  collate_sql
  command_sql
  comment_sql
  mergetreettlaction_sql
  mergetreettl_sql
  transaction_sql
  commit_sql
  rollback_sql
  altercolumn_sql
  renametable_sql
  renamecolumn_sql
  altertable_sql
  add_column_sql
  droppartition_sql
  addconstraint_sql
  distinct_sql
  ignorenulls_sql
  respectnulls_sql
  havingmax_sql
  intdiv_sql
  dpipe_sql
  div_sql
  overlaps_sql
  distance_sql
  dot_sql
  propertyeq_sql
  escape_sql
  glob_sql
  gt_sql
  gte_sql
  ilike_sql
  ilikeany_sql
  is_sql
  like_sql
  likeany_sql
  similarto_sql
  lt_sql
  lte_sql
  mod_sql
  mul_sql
  nullsafeeq_sql
  nullsafeneq_sql
  slice_sql
  sub_sql
  trycast_sql
  try_sql
  log_sql
  use_sql
  binary
  function_fallback_sql
  func
  format_args
  too_wide
  format_time
  expressions
  op_expressions
  naked_property
  tag_sql
  token_sql
  userdefinedfunction_sql
  joinhint_sql
  kwarg_sql
  when_sql
  merge_sql
  tochar_sql
  tonumber_sql
  dictproperty_sql
  dictrange_sql
  dictsubproperty_sql
  clusteredbyproperty_sql
  anyvalue_sql
  querytransform_sql
  indexconstraintoption_sql
  checkcolumnconstraint_sql
  nvl2_sql
  comprehension_sql
  columnprefix_sql
  opclass_sql
  predict_sql
  forin_sql
  refresh_sql
  operator_sql
  toarray_sql
  tsordstotime_sql
  tsordstotimestamp_sql
  tsordstodate_sql
  unixdate_sql
  lastday_sql
  dateadd_sql
  arrayany_sql
  generateseries_sql
  struct_sql
  partitionrange_sql
  truncatetable_sql
  convert_sql
  copyparameter_sql
  credentials_sql
  copy_sql