summaryrefslogtreecommitdiffstats
path: root/sqlglot/expressions.py
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--sqlglot/expressions.py11
1 files changed, 10 insertions, 1 deletions
diff --git a/sqlglot/expressions.py b/sqlglot/expressions.py
index 8246769..ea2255d 100644
--- a/sqlglot/expressions.py
+++ b/sqlglot/expressions.py
@@ -4988,6 +4988,15 @@ class ApproxQuantile(Quantile):
arg_types = {"this": True, "quantile": True, "accuracy": False, "weight": False}
+class Rand(Func):
+ _sql_names = ["RAND", "RANDOM"]
+ arg_types = {"this": False}
+
+
+class Randn(Func):
+ arg_types = {"this": False}
+
+
class RangeN(Func):
arg_types = {"this": True, "expressions": True, "each": False}
@@ -6475,7 +6484,7 @@ def table_name(table: Table | str, dialect: DialectType = None, identify: bool =
raise ValueError(f"Cannot parse {table}")
return ".".join(
- part.sql(dialect=dialect, identify=True)
+ part.sql(dialect=dialect, identify=True, copy=False)
if identify or not SAFE_IDENTIFIER_RE.match(part.name)
else part.name
for part in table.parts