andygrove commented on PR #1943:
URL: 
https://github.com/apache/datafusion-comet/pull/1943#issuecomment-3024627259

   Here is a suggested test to add to `CometFuzzTestSuite`:
   
   ```scala
     test("from_unix_time") {
       val df = spark.read.parquet(filename)
       df.createOrReplaceTempView("t1")
       val fields = df.schema.fields.filter(_.dataType == DataTypes.LongType)
       val name = fields.head.name
       val sql = s"SELECT $name, from_unixtime($name) FROM t1 where $name 
BETWEEN -8334601211038 AND 8210266876799"
       spark.sql(sql).show()
       checkSparkAnswerAndOperator(sql)
     }
   ```
   
   If I remove the where clause then I see exceptions being thrown:
   
   ```
   org.apache.comet.CometNativeException: Cast error: Failed to convert 
-328382592908932039 to datetime for Timestamp(Second, 
Some("America/Los_Angeles"))
   ```
   


-- 
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-unsubscr...@datafusion.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org
For additional commands, e-mail: github-h...@datafusion.apache.org

Reply via email to