explain.depesz.com

PostgreSQL's explain analyze made readable

Result: nn42

Settings
# exclusive inclusive rows x rows loops node
1. 0.204 1,955.446 ↓ 67.0 67 1

Nested Loop (cost=76.00..178,136.91 rows=1 width=134) (actual time=11.683..1,955.446 rows=67 loops=1)

2. 0.796 1,954.840 ↓ 67.0 67 1

Nested Loop (cost=75.72..178,136.59 rows=1 width=245) (actual time=11.669..1,954.840 rows=67 loops=1)

3. 0.293 1,953.387 ↓ 73.0 73 1

Merge Join (cost=75.43..178,134.47 rows=1 width=198) (actual time=11.640..1,953.387 rows=73 loops=1)

  • Merge Cond: ((protection_job_runs_0015000002i3ckvaav.cluster_identifier)::text = (registered_sources.cluster_identifier)::text)
  • Join Filter: (protection_job_runs_0015000002i3ckvaav.parent_source_id = registered_sources.source_id)
  • Rows Removed by Join Filter: 1060
4. 0.119 1,952.830 ↑ 7.5 73 1

Merge Join (cost=75.15..177,997.86 rows=548 width=176) (actual time=11.593..1,952.830 rows=73 loops=1)

  • Merge Cond: ((protection_job_runs_0015000002i3ckvaav.cluster_identifier)::text = (cluster.cluster_identifier)::text)
5. 477.098 1,952.629 ↑ 1,383.5 73 1

GroupAggregate (cost=74.88..176,673.13 rows=100,997 width=134) (actual time=11.576..1,952.629 rows=73 loops=1)

  • Group Key: protection_job_runs_0015000002i3ckvaav.cluster_identifier, protection_job_runs_0015000002i3ckvaav.parent_source_id, protection_job_runs_0015000002i3ckvaav.view_box_id, protection_job_runs_0015000002i3ckvaav.job_id
6. 332.196 1,475.531 ↑ 1.0 822,941 1

Merge Semi Join (cost=74.88..144,012.10 rows=830,562 width=74) (actual time=11.250..1,475.531 rows=822,941 loops=1)

  • Merge Cond: ((protection_job_runs_0015000002i3ckvaav.cluster_identifier)::text = (view_boxes_1.cluster_identifier)::text)
  • Join Filter: (protection_job_runs_0015000002i3ckvaav.view_box_id = view_boxes_1.view_box_id)
  • Rows Removed by Join Filter: 1065099
7. 305.839 1,086.558 ↑ 1.0 823,262 1

Merge Semi Join (cost=66.26..140,589.96 rows=830,562 width=104) (actual time=11.185..1,086.558 rows=823,262 loops=1)

  • Merge Cond: (((protection_job_runs_0015000002i3ckvaav.cluster_identifier)::text = (registered_sources_1.cluster_identifier)::text) AND (protection_job_runs_0015000002i3ckvaav.parent_source_id = registered_sources_1.source_id))
8. 780.046 780.046 ↑ 1.0 1,009,856 1

Index Scan using protection_job_runs_0015000002i3ckvaav_cid_pid_vid_jid on protection_job_runs_0015000002i3ckvaav (cost=0.55..135,449.05 rows=1,009,966 width=74) (actual time=0.022..780.046 rows=1,009,856 loops=1)

  • Filter: ((account_id)::text = '0015000002I3CkVAAV'::text)
9. 0.063 0.673 ↑ 1.0 39 1

Sort (cost=65.71..65.81 rows=39 width=38) (actual time=0.637..0.673 rows=39 loops=1)

  • Sort Key: registered_sources_1.cluster_identifier, registered_sources_1.source_id
  • Sort Method: quicksort Memory: 28kB
10. 0.610 0.610 ↑ 1.0 39 1

Seq Scan on registered_sources registered_sources_1 (cost=0.00..64.68 rows=39 width=38) (actual time=0.018..0.610 rows=39 loops=1)

  • Filter: ((cluster_identifier)::text = ANY ('{2690990343931928:1548976579658,4753914011867584:1537769063609,4590240874833370:1553378360317,3358568177796484:1552939875724,3773445208992781:1552938645523,8374834709413972:1535586101500,1616226053966050:1530308452261}'::text[]))
  • Rows Removed by Filter: 1544
11. 56.631 56.777 ↓ 25,978.2 1,065,108 1

Materialize (cost=0.28..170.55 rows=41 width=38) (actual time=0.050..56.777 rows=1,065,108 loops=1)

12. 0.146 0.146 ↑ 1.1 37 1

Index Only Scan using view_boxes_pkey on view_boxes view_boxes_1 (cost=0.28..170.44 rows=41 width=38) (actual time=0.045..0.146 rows=37 loops=1)

  • Index Cond: (cluster_identifier = ANY ('{2690990343931928:1548976579658,4753914011867584:1537769063609,4590240874833370:1553378360317,3358568177796484:1552939875724,3773445208992781:1552938645523,8374834709413972:1535586101500,1616226053966050:1530308452261}'::text[]))
  • Heap Fetches: 37
13. 0.016 0.082 ↓ 9.0 63 1

Materialize (cost=0.28..54.07 rows=7 width=42) (actual time=0.013..0.082 rows=63 loops=1)

14. 0.066 0.066 ↑ 1.2 6 1

Index Scan using cluster_pkey on cluster (cost=0.28..54.05 rows=7 width=42) (actual time=0.012..0.066 rows=6 loops=1)

  • Index Cond: ((cluster_identifier)::text = ANY ('{2690990343931928:1548976579658,4753914011867584:1537769063609,4590240874833370:1553378360317,3358568177796484:1552939875724,3773445208992781:1552938645523,8374834709413972:1535586101500,1616226053966050:1530308452261}'::text[]))
15. 0.112 0.264 ↓ 28.8 1,123 1

Materialize (cost=0.28..134.57 rows=39 width=38) (actual time=0.027..0.264 rows=1,123 loops=1)

16. 0.152 0.152 ↑ 1.0 39 1

Index Scan using registered_sources_pkey on registered_sources (cost=0.28..134.47 rows=39 width=38) (actual time=0.025..0.152 rows=39 loops=1)

  • Index Cond: ((cluster_identifier)::text = ANY ('{2690990343931928:1548976579658,4753914011867584:1537769063609,4590240874833370:1553378360317,3358568177796484:1552939875724,3773445208992781:1552938645523,8374834709413972:1535586101500,1616226053966050:1530308452261}'::text[]))
17. 0.657 0.657 ↑ 1.0 1 73

Index Scan using protection_jobs_pkey on protection_jobs (cost=0.29..2.11 rows=1 width=63) (actual time=0.008..0.009 rows=1 loops=73)

  • Index Cond: (((cluster_identifier)::text = (protection_job_runs_0015000002i3ckvaav.cluster_identifier)::text) AND ((cluster_identifier)::text = ANY ('{26909903439313370:1553378360317,3358568177796484:1552939875724,3773445208992781:1552938645523,8374834709413972:1535586101500,1616226053966050:1530308452261}'::text[])) AND (job_id = protection_job_runs_0015000002i3ckvaav.job_id))
18. 0.402 0.402 ↑ 1.0 1 67

Index Scan using view_boxes_pkey on view_boxes (cost=0.28..0.31 rows=1 width=55) (actual time=0.005..0.006 rows=1 loops=67)

  • Index Cond: (((cluster_identifier)::text = (protection_job_runs_0015000002i3ckvaav.cluster_identifier)::text) AND (view_box_id = protection_job_runs_0015000002i3ckvaav.view_box_id))