I have a mysql table that includes columns of type TIME. When I try to read the value in Python, normally used in mysql.connector, I would expect to get value of data type datetime.time() or a similar type that refers to a time that does not include a date. Instead I get data of type datetime.timedelta(). Is there a simple way to convert the data to a more appropriate type?
Asked
Active
Viewed 70 times
0
-
Please attach a reproducible example of your code and the query you are using. – Libra Nov 16 '21 at 14:42
-
Does this answer your question? [How to convert a timedelta object into a datetime object](https://stackoverflow.com/questions/2413391/how-to-convert-a-timedelta-object-into-a-datetime-object) – Libra Nov 16 '21 at 14:43