You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Zack Behringer (JIRA)" <ji...@apache.org> on 2018/10/09 14:23:00 UTC
[jira] [Created] (SPARK-25686) date_trunc Spark SQL function
silently returns null if parameters are swapped
Zack Behringer created SPARK-25686:
--------------------------------------
Summary: date_trunc Spark SQL function silently returns null if parameters are swapped
Key: SPARK-25686
URL: https://issues.apache.org/jira/browse/SPARK-25686
Project: Spark
Issue Type: Improvement
Components: SQL
Affects Versions: 2.3.1, 2.3.0
Reporter: Zack Behringer
date_trunc(a_timestamp, 'minute') returns null
date_trunc('minute', a_timestamp) returns a valid timestamp
it would be nice to have a runtime error to help catch the problem
This was not helped by the fact that the doc examples had it swapped, but yes I should have tested our use of it more thoroughly
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org