Merging upstream version 20.9.0.
Signed-off-by: Daniel Baumann <daniel@debian.org>
This commit is contained in:
parent
9421b254ec
commit
37a231f554
144 changed files with 78309 additions and 59609 deletions
|
@ -1,6 +1,7 @@
|
|||
from __future__ import annotations
|
||||
|
||||
from sqlglot import exp
|
||||
from sqlglot.dialects.dialect import merge_without_target_sql
|
||||
from sqlglot.dialects.presto import Presto
|
||||
|
||||
|
||||
|
@ -11,6 +12,7 @@ class Trino(Presto):
|
|||
TRANSFORMS = {
|
||||
**Presto.Generator.TRANSFORMS,
|
||||
exp.ArraySum: lambda self, e: f"REDUCE({self.sql(e, 'this')}, 0, (acc, x) -> acc + x, acc -> acc)",
|
||||
exp.Merge: merge_without_target_sql,
|
||||
}
|
||||
|
||||
class Tokenizer(Presto.Tokenizer):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue