Merging upstream version 23.13.1.
Signed-off-by: Daniel Baumann <daniel@debian.org>
This commit is contained in:
parent
63a75c51ff
commit
64041d1d66
85 changed files with 53899 additions and 50390 deletions
|
@ -161,6 +161,9 @@ class _Dialect(type):
|
|||
if enum not in ("", "bigquery"):
|
||||
klass.generator_class.SELECT_KINDS = ()
|
||||
|
||||
if enum not in ("", "athena", "presto", "trino"):
|
||||
klass.generator_class.TRY_SUPPORTED = False
|
||||
|
||||
if enum not in ("", "databricks", "hive", "spark", "spark2"):
|
||||
modifier_transforms = klass.generator_class.AFTER_HAVING_MODIFIER_TRANSFORMS.copy()
|
||||
for modifier in ("cluster", "distribute", "sort"):
|
||||
|
@ -318,6 +321,9 @@ class Dialect(metaclass=_Dialect):
|
|||
UNICODE_START: t.Optional[str] = None
|
||||
UNICODE_END: t.Optional[str] = None
|
||||
|
||||
# Separator of COPY statement parameters
|
||||
COPY_PARAMS_ARE_CSV = True
|
||||
|
||||
@classmethod
|
||||
def get_or_raise(cls, dialect: DialectType) -> Dialect:
|
||||
"""
|
||||
|
@ -897,9 +903,7 @@ def regexp_extract_sql(self: Generator, expression: exp.RegexpExtract) -> str:
|
|||
|
||||
|
||||
def regexp_replace_sql(self: Generator, expression: exp.RegexpReplace) -> str:
|
||||
bad_args = list(
|
||||
filter(expression.args.get, ("position", "occurrence", "parameters", "modifiers"))
|
||||
)
|
||||
bad_args = list(filter(expression.args.get, ("position", "occurrence", "modifiers")))
|
||||
if bad_args:
|
||||
self.unsupported(f"REGEXP_REPLACE does not support the following arg(s): {bad_args}")
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue