#2520 closed defect (fixed)
[patch] Invalid SQL generated when searching, using Foreign Keys in ordering but not in searching
Description ¶
A ProgrammingError, missing FROM-clause entry is generated in the following specific conditions:
- A Foreign Key is used in model.Meta.ordering
- The Foreign Key is NOT in the model.Admin.search_fields
- You perform a search.
The JOIN is not made with the Foreign Key, but it is listed in the ORDER BY clause.
Change History (3)
by , 19 years ago
Attachment: | django_admin_change_list_order_bug.diff added |
---|
comment:1 by , 19 years ago
Summary: | Invalid SQL generated when searching, using Foreign Keys in ordering but not in searching → [patch] Invalid SQL generated when searching, using Foreign Keys in ordering but not in searching |
---|
comment:2 by , 19 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Note:
See TracTickets
for help on using tickets.
Fixed #2520.