We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9a2349b commit 6da7905Copy full SHA for 6da7905
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/Cast.scala
@@ -106,7 +106,7 @@ object Cast {
106
* * Cast.castToTimestamp
107
*/
108
def needsTimeZone(from: DataType, to: DataType): Boolean = (from, to) match {
109
- case (StringType, TimestampType) => true
+ case (StringType, TimestampType | DateType) => true
110
case (DateType, TimestampType) => true
111
case (TimestampType, StringType) => true
112
case (TimestampType, DateType) => true
0 commit comments