Modify

Opened 15 years ago

Closed 14 years ago

Last modified 14 years ago

#4364 closed enhancement (duplicate)

SQL for report to sort tickets based on number of votes

Reported by: Luke Schierer Owned by: Ryan J Ollos
Priority: normal Component: VotePlugin
Severity: normal Keywords:
Cc: vincent Trac Release: 0.11

Description

It would be awesome if you could sort tickets based on the number of votes they have received.

Attachments (0)

Change History (8)

comment:1 Changed 15 years ago by anonymous

what about his ticket? There you find a sample SQL query #3655

comment:2 Changed 15 years ago by anonymous

here is some draft

SELECT ticket.id AS ticket , COUNT(votes.resource) AS vote, status, severity, priority, owner, time as created, summary

FROM ticket LEFT OUTER JOIN votes ON ('ticket/'
ticket.id = votes.resource)

WHERE ticket.status IN ('new', 'assigned', 'reopened')

GROUP BY ticket.id ORDER BY vote DESC

comment:3 Changed 15 years ago by vincent

Cc: vincent added; anonymous removed

comment:4 Changed 14 years ago by Ryan J Ollos

Owner: changed from Alec Thomas to Ryan J Ollos

Reassigning ticket to new maintainer.

comment:5 Changed 14 years ago by Ryan J Ollos

Resolution: worksforme
Status: newclosed

Duplicate of #3655.

comment:6 Changed 14 years ago by Ryan J Ollos

Resolution: worksforme
Status: closedreopened

comment:7 Changed 14 years ago by Ryan J Ollos

Resolution: duplicate
Status: reopenedclosed

comment:8 Changed 14 years ago by Ryan J Ollos

Summary: sort tickets by votesSQL for report to sort tickets based on number of votes

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Ryan J Ollos.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.