{16} Active Tickets by number

  • List all active tickets by number.
  • Color each row based on priority.
  • If a ticket has been accepted, a '*' is appended after the owner's name
Report execution failed:
ProgrammingError: invalid reference to FROM-clause entry for table "t"
LINE 11:        (t.id=tc_tc.ticket AND tc_tc.name='testcase')
HINT:  There is an entry for table "t", but it cannot be referenced from this part of the query.

SELECT p.value AS __color__,
   id AS ticket, summary, component, version, milestone, t.type AS type, priority, 
   (CASE WHEN tc_tc.value ISNULL THEN '' ELSE tc_tc.value END) AS "test case",
   owner, status,
   time AS created,
   changetime AS _changetime, description AS _description,
   reporter AS _reporter
  FROM ticket t, enum p
  LEFT OUTER JOIN ticket_custom tc_tc ON
       (t.id=tc_tc.ticket AND tc_tc.name='testcase')
  WHERE status <> 'closed' 
    AND p.name = t.priority AND p.type = 'priority'
  ORDER BY t.id

) AS tab
Note: See TracReports for help on using and creating reports.