diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2023-08-10 09:23:46 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2023-08-10 09:23:46 +0000 |
commit | 5dde903f4f6659e384287a3e508b9f369c5a2ba3 (patch) | |
tree | 05cd2920d82f0023f6ac695dbb6eaeef64608401 /sqlglot/dialects/teradata.py | |
parent | Adding upstream version 17.9.1. (diff) | |
download | sqlglot-5dde903f4f6659e384287a3e508b9f369c5a2ba3.tar.xz sqlglot-5dde903f4f6659e384287a3e508b9f369c5a2ba3.zip |
Adding upstream version 17.11.0.upstream/17.11.0
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'sqlglot/dialects/teradata.py')
-rw-r--r-- | sqlglot/dialects/teradata.py | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/sqlglot/dialects/teradata.py b/sqlglot/dialects/teradata.py index 3fac4f5..2be1a62 100644 --- a/sqlglot/dialects/teradata.py +++ b/sqlglot/dialects/teradata.py @@ -1,5 +1,7 @@ from __future__ import annotations +import typing as t + from sqlglot import exp, generator, parser, tokens, transforms from sqlglot.dialects.dialect import Dialect, max_or_greatest, min_or_least from sqlglot.tokens import TokenType @@ -194,11 +196,7 @@ class Teradata(Dialect): return f"RANGE_N({this} BETWEEN {expressions_sql}{each_sql})" - def createable_sql( - self, - expression: exp.Create, - locations: dict[exp.Properties.Location, list[exp.Property]], - ) -> str: + def createable_sql(self, expression: exp.Create, locations: t.DefaultDict) -> str: kind = self.sql(expression, "kind").upper() if kind == "TABLE" and locations.get(exp.Properties.Location.POST_NAME): this_name = self.sql(expression.this, "this") @@ -209,4 +207,5 @@ class Teradata(Dialect): ) this_schema = self.schema_columns_sql(expression.this) return f"{this_name}{this_properties}{self.sep()}{this_schema}" + return super().createable_sql(expression, locations) |