You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Max Gekk (Jira)" <ji...@apache.org> on 2022/03/11 07:48:00 UTC
[jira] [Resolved] (SPARK-38509) Unregister the TIMESTAMPADD/DIFF functions and remove DATE_ADD/DIFF
[ https://issues.apache.org/jira/browse/SPARK-38509?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Max Gekk resolved SPARK-38509.
------------------------------
Fix Version/s: 3.3.0
Resolution: Fixed
Issue resolved by pull request 35805
[https://github.com/apache/spark/pull/35805]
> Unregister the TIMESTAMPADD/DIFF functions and remove DATE_ADD/DIFF
> -------------------------------------------------------------------
>
> Key: SPARK-38509
> URL: https://issues.apache.org/jira/browse/SPARK-38509
> Project: Spark
> Issue Type: Improvement
> Components: SQL
> Affects Versions: 3.3.0
> Reporter: Max Gekk
> Assignee: Max Gekk
> Priority: Major
> Fix For: 3.3.0
>
>
> 1. Unregister the functions `timestampadd()` and `timestampdiff()` in `FunctionRegistry.expressions`.
> 2. Remove the aliases `date_add` for `timestampadd()` and `date_diff` for `timestampdiff()`.
> 3. Align tests (regenerate golden files) to the syntax rules
> where the first parameter `unit` can have one of the identifiers:
> - YEAR
> - QUARTER
> - MONTH
> - WEEK
> - DAY, DAYOFYEAR (valid for timestampadd)
> - HOUR
> - MINUTE
> - SECOND
> - MILLISECOND
> - MICROSECOND
> h4. Why are the changes needed?
> 1. The `timestampadd()`/`timestampdiff()` functions (and their aliases) with arbitrary string column as the first parameter is not require by any standard.
> 2. Remove the functions and aliases should reduce maintenance cost.
--
This message was sent by Atlassian Jira
(v8.20.1#820001)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org