You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@datafusion.apache.org by "vaibhawvipul (via GitHub)" <gi...@apache.org> on 2024/05/01 07:10:59 UTC
Re: [PR] feat: Implement Spark-compatible CAST from string to timestamp types [datafusion-comet]
vaibhawvipul commented on code in PR #335:
URL: https://github.com/apache/datafusion-comet/pull/335#discussion_r1585961551
##########
spark/src/test/scala/org/apache/comet/CometCastSuite.scala:
##########
@@ -109,10 +109,12 @@ class CometCastSuite extends CometTestBase with AdaptiveSparkPlanHelper {
"spark.comet.cast.stringToTimestamp is disabled")
}
- ignore("cast string to timestamp") {
- withSQLConf((CometConf.COMET_CAST_STRING_TO_TIMESTAMP.key, "true")) {
- val values = Seq("2020-01-01T12:34:56.123456", "T2") ++ generateStrings(timestampPattern, 8)
- castTest(values.toDF("a"), DataTypes.TimestampType)
+ test("cast string to timestamp") {
+ withSQLConf(
+ (SQLConf.SESSION_LOCAL_TIMEZONE.key -> "UTC"),
Review Comment:
@andygrove I would need some help here. Do you want me to add a check here?
https://github.com/apache/datafusion-comet/blob/c90081996c3b0537695f1fd68bdef9aa22e08a68/spark/src/main/scala/org/apache/comet/serde/QueryPlanSerde.scala#L578
--
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: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org