[
https://issues.apache.org/jira/browse/SPARK-33015?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17203092#comment-17203092
]
Apache Spark commented on SPARK-33015:
--------------------------------------
User 'MaxGekk' has created a pull request for this issue:
https://github.com/apache/spark/pull/29889
> Compute the current date only once
> ----------------------------------
>
> Key: SPARK-33015
> URL: https://issues.apache.org/jira/browse/SPARK-33015
> Project: Spark
> Issue Type: Bug
> Components: SQL
> Affects Versions: 3.0.2, 3.1.0
> Reporter: Maxim Gekk
> Priority: Major
>
> According to the doc for current_date(), it must compute the current date at
> the start of query evaluation:
> http://spark.apache.org/docs/latest/api/sql/#current_date but it can compute
> it multiple times:
> https://github.com/apache/spark/blob/0df8dd60733066076967f0525210bbdb5e12415a/sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/optimizer/finishAnalysis.scala#L85
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]