explain.depesz.com

PostgreSQL's explain analyze made readable

Result: Nf5W : delete duplicates

Settings
# exclusive inclusive rows x rows loops node
1. 9.170 10,005,537.112 ↓ 0.0 0 1

ModifyTable on public.ci_job_artifacts (cost=12,840,737.52..25,656,423.41 rows=117,402 width=6) (actual time=10,005,537.112..10,005,537.112 rows=0 loops=1)

  • Buffers: shared hit=263,192 read=11,154,704 dirtied=20,172 written=178
  • I/O Timings: read=9,816,699.509 write=6.467
2. 5,078,418.654 10,005,527.942 ↑ 11,740.2 10 1

Index Scan using index_ci_job_artifacts_on_job_id_and_file_type on public.ci_job_artifacts (cost=12,840,737.52..25,656,423.41 rows=117,402 width=6) (actual time=5,886,006.979..10,005,527.942 rows=10 loops=1)

  • Index Cond: (ci_job_artifacts.file_type = ANY ('{10,101}'::integer[]))
  • Filter: (NOT (hashed SubPlan 1))
  • Rows Removed by Filter: 237,573
  • Buffers: shared hit=263,178 read=11,154,700 dirtied=20,158 written=178
  • I/O Timings: read=9,816,691.558 write=6.467
3.          

SubPlan (for Index Scan)

4. 150.648 4,927,109.288 ↓ 1.0 237,573 1

Aggregate (cost=12,836,045.26..12,840,150.81 rows=234,452 width=8) (actual time=4,926,894.006..4,927,109.288 rows=237,573 loops=1)

  • Group Key: ci_job_artifacts_1.job_id
  • Buffers: shared hit=258,510 read=5,450,643 dirtied=20,158 written=6
  • I/O Timings: read=4,831,645.972 write=0.675
5. 1,792.873 4,926,958.640 ↓ 1.0 237,583 1

Sort (cost=12,836,045.26..12,836,632.27 rows=234,804 width=8) (actual time=4,926,893.924..4,926,958.640 rows=237,583 loops=1)

  • Sort Key: ci_job_artifacts_1.job_id
  • Sort Method: quicksort Memory: 17,281kB
  • Buffers: shared hit=258,510 read=5,450,643 dirtied=20,158 written=6
  • I/O Timings: read=4,831,645.972 write=0.675
6. 4,925,165.767 4,925,165.767 ↓ 1.0 237,583 1

Index Scan using index_ci_job_artifacts_on_job_id_and_file_type on public.ci_job_artifacts ci_job_artifacts_1 (cost=0.57..12,815,099.46 rows=234,804 width=8) (actual time=2,256.216..4,925,165.767 rows=237,583 loops=1)

  • Index Cond: (ci_job_artifacts_1.file_type = ANY ('{10,101}'::integer[]))
  • Buffers: shared hit=258,507 read=5,450,643 dirtied=20,158 written=6
  • I/O Timings: read=4,831,645.972 write=0.675