Skip to content

Instantly share code, notes, and snippets.

Created March 16, 2017 15:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/61f89affbf9a3d2bd872eb24d58fec01 to your computer and use it in GitHub Desktop.
Save anonymous/61f89affbf9a3d2bd872eb24d58fec01 to your computer and use it in GitHub Desktop.
Delete on minion_jobs j (cost=0.43..16363249.99 rows=8 width=12)
-> Nested Loop Anti Join (cost=0.43..16363249.99 rows=8 width=12)
Join Filter: (j.id = ANY (minion_jobs.parents))
-> Index Scan using minion_jobs_finished_idx on minion_jobs j (cost=0.43..22936.87 rows=8013 width=14)
Index Cond: (finished <= (now() - '48:00:00'::interval))
Filter: (state = 'finished'::minion_state)
-> Materialize (cost=0.00..94587.74 rows=86973 width=37)
-> Seq Scan on minion_jobs (cost=0.00..93472.88 rows=86973 width=37)
Filter: (state <> 'finished'::minion_state)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment