#33590: Column from view which has a left outer join invalidly becomes NULL
(including coalesce) over a django cursor, but not via a direct psycopg2
cursor
----------------------------------+--------------------------------------
Reporter: Stefan de Konink | Owner: nobody
Type: Bug | Status: new
Component: Uncategorized | Version: 4.0
Severity: Normal | Resolution:
Keywords: | Triage Stage: Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
----------------------------------+--------------------------------------
Comment (by Stefan de Konink):
Was able to figure out the difference in the connection setup between
psycopg2 native and Django. The latter applied {{{set time zone 'utc';}}}
when setting up the connection. That rules out that Django itself is the
problem.
{{{
blxa=> select * from myview ;
id | scheduled | exact_schedule_id |
negative_schedule_id
------------+---------------------+-------------------+----------------------
1647824400 | 2022-03-21 01:00:00 | 1 |
1
1647824400 | 2022-03-21 01:00:00 | 1 |
1
1647824400 | 2022-03-21 01:00:00 | 1 |
1
(3 rows)
blxa=> set time zone 'utc';
SET
blxa=> select * from myview ;
id | scheduled | exact_schedule_id |
negative_schedule_id
------------+---------------------+-------------------+----------------------
1647824400 | 2022-03-21 01:00:00 | 1 |
0
(1 row)
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/33590#comment:8>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-updates/0107017fabe5c50b-49387e3b-4a2c-4258-a2c5-e53a6f9142c4-000000%40eu-central-1.amazonses.com.