clay
02/09/2023, 6:28 PMSnowflakePandasTypeHandler
know how to convert a python datetime object (datetime.datetime.now()
) into a timestamp column in Snowflake when materializing a DataFrame?jamie
02/09/2023, 6:33 PMclay
02/09/2023, 6:33 PMjamie
02/09/2023, 6:34 PMjamie
02/09/2023, 6:34 PMclay
02/09/2023, 6:35 PMjamie
02/10/2023, 4:54 PMinvalid date
and then when a downstream asset tries to load the data i get the error
sqlalchemy.exc.InterfaceError: (snowflake.connector.errors.InterfaceError) 252005: Failed to convert current row, cause: year 47005047 is out of range
(Background on this error at: <https://sqlalche.me/e/14/rvf5>)
which is the same error i get with pandas timestamps.
However, the workaround in the io manager is to turn date-like objects into strings and then store them in the db. And that is working as expected with datetime
objects. if you happen to run into the issue again definitely let me know