diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2023-07-10 05:36:29 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2023-07-10 05:36:29 +0000 |
commit | 49af28576db02470fe1d2de04e3901309b60c2e4 (patch) | |
tree | 63e63864ce7f62e9288ccb9ee438eddba08c6d49 /sqlglot/dialects/spark.py | |
parent | Releasing debian version 17.2.0-1. (diff) | |
download | sqlglot-49af28576db02470fe1d2de04e3901309b60c2e4.tar.xz sqlglot-49af28576db02470fe1d2de04e3901309b60c2e4.zip |
Merging upstream version 17.3.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'sqlglot/dialects/spark.py')
-rw-r--r-- | sqlglot/dialects/spark.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/sqlglot/dialects/spark.py b/sqlglot/dialects/spark.py index 7a7ee01..73f4370 100644 --- a/sqlglot/dialects/spark.py +++ b/sqlglot/dialects/spark.py @@ -41,6 +41,12 @@ class Spark(Spark2): } class Generator(Spark2.Generator): + TYPE_MAPPING = { + **Spark2.Generator.TYPE_MAPPING, + exp.DataType.Type.MONEY: "DECIMAL(15, 4)", + exp.DataType.Type.SMALLMONEY: "DECIMAL(6, 4)", + exp.DataType.Type.UNIQUEIDENTIFIER: "STRING", + } TRANSFORMS = Spark2.Generator.TRANSFORMS.copy() TRANSFORMS.pop(exp.DateDiff) TRANSFORMS.pop(exp.Group) |