Opened 18 years ago

Closed 18 years ago

#1152 closed defect (invalid)

distinct keyword in model seems not working

Reported by: hipertracker@… Owned by: Adrian Holovaty
Component: Core (Other) Version: 0.90
Severity: normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

How to limit records with "distinct" keywords if every model seems to return all fields (together with primary key)? SELECT DISTINCT field1,field2 ... has sense only when primary key is not included in the field list. I checked the code and I could see Django always uses fields defined in model class + primary key...

Change History (1)

comment:1 by Adrian Holovaty, 18 years ago

Resolution: invalid
Status: newclosed
Note: See TracTickets for help on using tickets.
Back to Top