explain.depesz.com

PostgreSQL's explain analyze made readable

Result: H6Ns

Settings
# exclusive inclusive rows x rows loops node
1. 0.002 2.631 ↓ 0.0 0 1

ModifyTable on public.ci_job_artifacts (cost=71.92..530.57 rows=291,687,552 width=34) (actual time=2.631..2.631 rows=0 loops=1)

  • Buffers: shared hit=177
2.          

CTE ci_job_artifacts_with_row_number

3. 1.193 2.218 ↓ 1.5 1,000 1

WindowAgg (cost=0.42..55.87 rows=663 width=16) (actual time=0.138..2.218 rows=1,000 loops=1)

  • Buffers: shared hit=177
4. 1.025 1.025 ↓ 1.5 1,000 1

Index Only Scan using i1 on public.ci_job_artifacts ci_job_artifacts_1 (cost=0.42..44.27 rows=663 width=8) (actual time=0.115..1.025 rows=1,000 loops=1)

  • Index Cond: ((ci_job_artifacts_1.job_id >= 409,207,962) AND (ci_job_artifacts_1.job_id < 411364719))
  • Heap Fetches: 26
  • Buffers: shared hit=177
5. 0.001 2.629 ↓ 0.0 0 1

Nested Loop (cost=16.04..474.70 rows=291,687,552 width=34) (actual time=2.628..2.629 rows=0 loops=1)

  • Buffers: shared hit=177
6. 0.004 2.628 ↓ 0.0 0 1

HashAggregate (cost=15.47..16.95 rows=148 width=32) (actual time=2.628..2.628 rows=0 loops=1)

  • Group Key: ci_job_artifacts_with_row_number.id
  • Buffers: shared hit=177
7. 2.624 2.624 ↓ 0.0 0 1

CTE Scan on ci_job_artifacts_with_row_number (cost=0.00..14.92 rows=221 width=32) (actual time=2.624..2.624 rows=0 loops=1)

  • Filter: (ci_job_artifacts_with_row_number.row_number > 1)
  • Rows Removed by Filter: 1,000
  • Buffers: shared hit=177
8. 0.000 0.000 ↓ 0.0 0 0

Index Scan using ci_job_artifacts_pkey on public.ci_job_artifacts (cost=0.57..3.59 rows=1 width=10) (actual time=0.000..0.000 rows=0 loops=0)

  • Index Cond: (ci_job_artifacts.id = ci_job_artifacts_with_row_number.id)