I have a table with a column of type TIMESTAMP WITH TIME ZONE
and I try to simply SELECT * FROM table
, but I get this message:
postgresql error: '>=' not supported between instances of 'datetime.timedelta' and 'int'`
Am I entering the data incorrectly?
creation_datetime = datetime.now(timezone.utc)
...
new_record = {
"key": valid_value.contract.symbol.lower(),
"datetime_downloaded_from_api": creation_datetime
}
yield new_record
I use meltano and a singer custom TAP to retrieve and input the data.. meltano taps streams.py
has the part where I describe the data columns and did this
schema = th.PropertiesList(
th.Property("datetime_downloaded_from_api", th.DateTimeType),
th.Property("contract_id", th.IntegerType)
).to_dict()
turned out I needed a specific version of a python library to be installed
pip install psycopg2-binary==2.8.5