1
0
Fork 0

Adding upstream version 11.2.0.

Signed-off-by: Daniel Baumann <daniel@debian.org>
This commit is contained in:
Daniel Baumann 2025-02-13 15:28:28 +01:00
parent 85cdf062c9
commit adedb06cbd
Signed by: daniel
GPG key ID: FBB4F0E80A80222F
32 changed files with 25185 additions and 24026 deletions
sqlglot/dialects

View file

@ -8,6 +8,7 @@ from sqlglot.dialects.dialect import (
inline_array_sql,
rename_func,
timestrtotime_sql,
ts_or_ds_to_date_sql,
var_map_sql,
)
from sqlglot.expressions import Literal
@ -236,6 +237,7 @@ class Snowflake(Dialect):
exp.TimeStrToTime: timestrtotime_sql,
exp.TimeToUnix: lambda self, e: f"EXTRACT(epoch_second FROM {self.sql(e, 'this')})",
exp.Trim: lambda self, e: self.func("TRIM", e.this, e.expression),
exp.TsOrDsToDate: ts_or_ds_to_date_sql("snowflake"),
exp.UnixToTime: _unix_to_time_sql,
exp.DayOfWeek: rename_func("DAYOFWEEK"),
}