uros-db commented on code in PR #54950:
URL: https://github.com/apache/spark/pull/54950#discussion_r3241936645
##########
sql/core/src/test/resources/sql-tests/inputs/typeCoercion/native/implicitTypeCasts.sql:
##########
@@ -56,6 +56,10 @@ SELECT length('four') FROM t;
SELECT length(date('1996-09-10')) FROM t;
SELECT length(timestamp('1996-09-10 10:11:12.4')) FROM t;
+-- string to time
+SELECT '12:00:00' = TIME'12:00:00' FROM t;
+SELECT '12:00:01' > TIME'12:00:00' FROM t;
Review Comment:
Added the proposed SQL test that flows through ImplicitTypeCasts against
AnyTimeType: `SELECT time_trunc('HOUR', '12:34:56') FROM t;`. TimeTrunc has
inputTypes = Seq(StringTypeWithCollation(...), AnyTimeType) and mixes in
ImplicitCastInputTypes, so the second argument's coercion exercises the new
rule. Golden files in both analyzer-results/ and results/ updated accordingly.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]