Changes between Initial Version and Version 1 of Ticket #27241, comment 10
- Timestamp:
- Sep 20, 2016, 4:59:38 AM (8 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #27241, comment 10
initial v1 1 As far as Django is concerned these views do have a primary key (there's a id field, it even has a unique index). The problem is that at the database level this field isn't, and cannot, have a primary key constraint. Without a **real** primary key Postgres cannot group by primary key only, since they don't exist.1 As far as Django is concerned these views do have a primary key (there's a id field, it even has a unique index). The problem is that at the database level this field doesn't, and cannot, have a primary key constraint. Without a **real** primary key Postgres cannot group by primary key only, since they don't exist. 2 2 3 3 This is what happens if you try to add a PK to a (materialized) view: