Skip to content

Commit

Permalink
Add distinct to query to cut time spent in half
Browse files Browse the repository at this point in the history
git-svn-id: svn://test.kernel.org/autotest/trunk@1546 592f7852-d20e-0410-864c-8624ca9c26a4
  • Loading branch information
showard committed May 23, 2008
1 parent 29e3164 commit b44c03e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion scheduler/monitor_db
Original file line number Diff line number Diff line change
Expand Up @@ -508,7 +508,7 @@ class Dispatcher:
# better
_db.execute("""
DELETE ihq FROM ineligible_host_queues ihq
LEFT JOIN (SELECT job_id FROM host_queue_entries
LEFT JOIN (SELECT DISTINCT job_id FROM host_queue_entries
WHERE NOT complete) hqe
USING (job_id) WHERE hqe.job_id IS NULL""")

Expand Down

0 comments on commit b44c03e

Please sign in to comment.