Max Gekk created SPARK-47072:
--------------------------------
Summary: Wrong error message for incorrect ANSI intervals
Key: SPARK-47072
URL: https://issues.apache.org/jira/browse/SPARK-47072
Project: Spark
Issue Type: Bug
Components: SQL
Affects Versions: 4.0.0
Reporter: Max Gekk
Assignee: Max Gekk
When Spark SQL cannot recognise ANSI interval, it outputs wrong pattern for
particular ANSI interval. For example, it cannot recognise year-month interval,
but says about day-time interval:
{code:sql}
spark-sql (default)> select interval '-\t2-2\t' year to month;
Interval string does not match year-month format of `[+|-]d h`, `INTERVAL
[+|-]'[+|-]d h' DAY TO HOUR` when cast to interval year to month: - 2-2 .
(line 1, pos 16)
== SQL ==
select interval '-\t2-2\t' year to month
----------------^^^
{code}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]