explain.depesz.com

PostgreSQL's explain analyze made readable

Result: Nv1p : jobs

Settings

Optimization(s) for this plan:

# exclusive inclusive rows x rows loops node
1. 12.552 16,813.989 ↑ 42.1 3,108 1

Nested Loop (cost=165.36..56,810.64 rows=130,863 width=1,326) (actual time=6,182.569..16,813.989 rows=3,108 loops=1)

2. 8.144 14.333 ↓ 210.1 4,622 1

HashAggregate (cost=46.83..47.05 rows=22 width=37) (actual time=8.480..14.333 rows=4,622 loops=1)

  • Group Key: (ticket_1.job_id)::text
3. 6.189 6.189 ↓ 210.1 4,622 1

Index Scan using idx_entity_op_created on ticket ticket_1 (cost=0.56..46.78 rows=22 width=37) (actual time=0.029..6.189 rows=4,622 loops=1)

  • Index Cond: (((op_type)::text = 'SDD_SNAPSHOT'::text) AND ((entity_id)::text = 'sdb-services-test10:sdb17'::text))
4. 10,665.415 16,787.104 ↑ 322.0 1 4,622

Bitmap Heap Scan on ticket (cost=118.53..2,576.94 rows=322 width=1,326) (actual time=3.631..3.632 rows=1 loops=4,622)

  • Recheck Cond: ((job_id)::text = (ticket_1.job_id)::text)
  • Filter: (NOT (hashed SubPlan 1))
  • Rows Removed by Filter: 461
  • Heap Blocks: exact=311533
5. 6,114.906 6,114.906 ↑ 1.4 465 4,622

Bitmap Index Scan on idx_job_op (cost=0.00..73.39 rows=644 width=0) (actual time=1.323..1.323 rows=465 loops=4,622)

  • Index Cond: ((job_id)::text = (ticket_1.job_id)::text)
6.          

SubPlan (for Bitmap Heap Scan)

7. 6.783 6.783 ↓ 219.8 4,615 1

Index Scan using idx_entity_op_created on ticket ticket_2 (cost=0.56..45.01 rows=21 width=37) (actual time=0.022..6.783 rows=4,615 loops=1)

  • Index Cond: (((op_type)::text = 'SDD_COPY_EXTENT_COMPLETE'::text) AND ((entity_id)::text = 'sdb-services-test10:sdb17'::text))
  • Filter: ((status)::text = ANY ('{COMPLETED,ABORT}'::text[]))
Planning time : 0.735 ms
Execution time : 16,814.245 ms