SM03/18/2023, 12:08 AM
Do I need to convert my Python datetimes into something else before using them in QuestDB queries? Edit: This is solved now. Seems like QuestDB needs datetimes to be naive and in utc, so what I did before using datetimes to filter rows in psycopg2 is the following (dt is a datetime object with some valid timezone):
psycopg2.DatabaseError: invalid constant: timestamptz LINE 1: ... timestamp <= '2023-03-17T19:55:46.342000+00:00'::timestampt...
dt = dt.astimezone(pytz.timezone("UTC")).replace(tzinfo=None)