Created
January 10, 2012 12:58
-
-
Save sassman/1588965 to your computer and use it in GitHub Desktop.
trac related stuff
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT p.value AS __color__, | |
'Component '||component AS __group__, | |
id AS ticket, summary, milestone, version, t.type AS type, | |
owner, status, | |
time AS created, | |
changetime AS _changetime, description AS _description, | |
reporter AS _reporter | |
FROM ticket t | |
LEFT JOIN enum p ON p.name = t.priority AND p.type = 'priority' | |
WHERE status <> 'closed' | |
ORDER BY (component IS NULL),component, CAST(p.value AS int), t.type, time |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment