I have a model which has a DateTimeField
for a start date as timestamp. When I'm creating new objects of the model and store them in the PostgreSQL database the given timezone is Europe/Berlin
.
I confirmed it just before calling save()
and the entries have the correct offsets in the database. The timezone of the database also matches with the timezone of the objects.
But when I retrieve objects of the model over .filter()
the timezone is set to UTC
, so I'm losing the timezone. Of course it should be Europe/Berlin
as well. Inside settings.py
is also the correct timezone:
TIME_ZONE = 'Europe/Berlin'
Can anybody help me?