#14285 closed (invalid)
Calling reverse() on order_by('a', 'b') produces order_by('-a')
| Reported by: | Martin Tsachev | Owned by: | nobody | 
|---|---|---|---|
| Component: | Database layer (models, ORM) | Version: | 1.2 | 
| Severity: | Keywords: | reverse order_by multiple columns | |
| Cc: | Triage Stage: | Unreviewed | |
| Has patch: | no | Needs documentation: | no | 
| Needs tests: | no | Patch needs improvement: | no | 
| Easy pickings: | no | UI/UX: | no | 
Description
If you have order_by for more than one column reverse() will use only the first one to generate the reverse query.
Example:
Calling reverse() on order_by('a', 'b') produces order_by('-a')
Expected:
order_by('-a', '-b')
Change History (2)
comment:1 by , 15 years ago
| Resolution: | → invalid | 
|---|---|
| Status: | new → closed | 
comment:2 by , 15 years ago
  Note:
 See   TracTickets
 for help on using tickets.
    
I used a Manager for order_by() instead of Meta.ordering.