alamb commented on code in PR #16639:
URL: https://github.com/apache/datafusion/pull/16639#discussion_r2183689441


##########
datafusion/sqllogictest/test_files/timestamps.slt:
##########
@@ -394,12 +503,12 @@ SELECT COUNT(*) FROM ts_data_secs where ts > 
to_timestamp_seconds('2020-09-08 12
 query PPP
 SELECT to_timestamp(1.1) as c1, cast(1.1 as timestamp) as c2, 1.1::timestamp 
as c3;
 ----
-1970-01-01T00:00:01.100 1970-01-01T00:00:01.100 1970-01-01T00:00:01.100
+1970-01-01T00:00:01.100 1970-01-01T00:00:00.000000001 
1970-01-01T00:00:00.000000001

Review Comment:
   Do I read this difference right as now `cast(float_col AS timestamp)` is 
treated as though it is 1.1 ns where as before it was treated as `1.1` sec?
   
   What do we think about simply not supporting explicit conversion from float 
--> timestamp to follow the duckdb/postgres model.  That feels far more 
defensible to me than this behavior which is both different than it was 
previously *AND* not consistent with other engines
   



-- 
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