Modify ↓
Opened 8 years ago
Closed 8 years ago
#13015 closed defect (fixed)
Custom field of type time cannot be sorted
| Reported by: | Owned by: | Jun Omae | |
|---|---|---|---|
| Priority: | normal | Milestone: | 1.2.3 |
| Component: | query system | Version: | 1.2 |
| Severity: | normal | Keywords: | postgresql |
| Cc: | Branch: | ||
| Release Notes: |
Fix |
||
| API Changes: | |||
| Internal Changes: | |||
Description
In [ticket-custom] we created a due date field for tickets:
duedate = time duedate.format = date duedate.label = Due date duedate.order = 14
Creating new tickets works and the field can be seen in custom queries, but pressing the column for sorting results in this error:
Trac detected an internal error:
ProgrammingError: COALESCE types text and integer cannot be matched
LINE 5: ORDER BY COALESCE("duedate".value,0)=0,"duedate".value,t.id)...
^
Attachments (0)
Change History (6)
comment:1 by , 8 years ago
comment:2 by , 8 years ago
Thanks for the patch but lead another issue when passing order=time to query page.
comment:3 by , 8 years ago
| Component: | ticket system → query system |
|---|---|
| Owner: | set to |
| Release Notes: | modified (diff) |
| Status: | new → assigned |
Proposed changes in [7cde3e59f/jomae.git].
comment:6 by , 8 years ago
| Resolution: | → fixed |
|---|---|
| Status: | assigned → closed |
Note:
See TracTickets
for help on using tickets.



Can be fixed with this patch:
query.py
or name in self.time_fields: