explain.depesz.com

PostgreSQL's explain analyze made readable

Result: uHIt

Settings
# exclusive inclusive rows x rows loops node
1. 0.722 588,338.035 ↓ 0.0 0 1

Insert on pg_temp_3.tmp_adg_cur_violocc (cost=13.87..13.90 rows=1 width=16) (actual time=588,338.035..588,338.035 rows=0 loops=1)

  • Buffers: shared hit=61478966, local hit=139 read=1 dirtied=1
2. 0.319 588,337.313 ↓ 140.0 140 1

Subquery Scan on *SELECT* (cost=13.87..13.90 rows=1 width=16) (actual time=588,336.842..588,337.313 rows=140 loops=1)

  • Output: "*SELECT*".diag_id, "*SELECT*".object_id, "*SELECT*".count
  • Buffers: shared hit=61478966
3. 0.976 588,336.994 ↓ 140.0 140 1

HashAggregate (cost=13.87..13.88 rows=1 width=16) (actual time=588,336.827..588,336.994 rows=140 loops=1)

  • Output: v.diag_id, v.object_id, count(r.metric_num_value)
  • Buffers: shared hit=61478966
4. 43.947 588,336.018 ↓ 140.0 140 1

Nested Loop (cost=0.00..13.87 rows=1 width=16) (actual time=63,143.939..588,336.018 rows=140 loops=1)

  • Output: v.diag_id, v.object_id, r.metric_num_value
  • Buffers: shared hit=61478966
5. 272,059.755 588,221.973 ↓ 5,007.0 5,007 1

Nested Loop (cost=0.00..8.25 rows=1 width=20) (actual time=603.627..588,221.973 rows=5,007 loops=1)

  • Output: v.diag_id, v.object_id, r.metric_num_value, r.metric_id
  • Join Filter: ((v.object_id = r.object_id) AND ((v.diag_id + 1) = r.metric_id))
  • Rows Removed by Join Filter: 227347643
  • Buffers: shared hit=61463945
6. 247.248 247.248 ↓ 45,745.0 45,745 1

Index Scan using dss_metr_res_idx2 on endtoend_839_central.dss_metric_results r (cost=0.00..4.34 rows=1 width=20) (actual time=0.014..247.248 rows=45,745 loops=1)

  • Output: r.metric_id, r.object_id, r.metric_value_index, r.metric_num_value, r.metric_char_value, r.metric_object_id, r.snapshot_id, r.position_id
  • Index Cond: (r.snapshot_id = 7)
  • Buffers: shared hit=28410
7. 315,914.970 315,914.970 ↓ 4,970.0 4,970 45,745

Index Scan using dss_violation_status_idx1 on endtoend_839_central.dss_violation_statuses v (cost=0.00..3.90 rows=1 width=12) (actual time=0.019..6.906 rows=4,970 loops=45,745)

  • Output: v.diag_id, v.object_id, v.snapshot_id, v.previous_snapshot_id, v.violation_status
  • Index Cond: ((v.snapshot_id = 7) AND (v.previous_snapshot_id = 1) AND (v.violation_status = 4))
  • Buffers: shared hit=61435535
8. 70.098 70.098 ↓ 0.0 0 5,007

Index Scan using dss_me_val_typ_pk on endtoend_839_central.dss_metric_value_types t (cost=0.00..5.61 rows=1 width=4) (actual time=0.014..0.014 rows=0 loops=5,007)

  • Output: t.metric_id, t.metric_value_index, t.metric_value_name, t.metric_value_description, t.metric_value_procedure_name, t.metric_aggregate_operator, t.metric_value_procedure_name_2, t.metric_aggregate_operator_2, t.metric_value_type
  • Index Cond: (t.metric_id = r.metric_id)
  • Filter: (t.metric_value_type = ANY ('{7,8}'::integer[]))
  • Rows Removed by Filter: 1
  • Buffers: shared hit=15021