explain.depesz.com

PostgreSQL's explain analyze made readable

Result: GVaw

Settings
# exclusive inclusive rows x rows loops node
1. 0.012 4,249.843 ↑ 1.0 200 1

Limit (cost=1,070,136.60..1,070,146.60 rows=200 width=122) (actual time=4,249.804..4,249.843 rows=200 loops=1)

2. 70.947 4,249.831 ↑ 3,644.1 200 1

WindowAgg (cost=1,070,136.60..1,106,577.55 rows=728,819 width=122) (actual time=4,249.803..4,249.831 rows=200 loops=1)

3. 297.399 4,178.884 ↑ 3.0 245,439 1

GroupAggregate (cost=1,070,136.60..1,090,179.12 rows=728,819 width=114) (actual time=3,855.839..4,178.884 rows=245,439 loops=1)

  • Group Key: i.id, boc.id
4. 117.410 3,881.485 ↑ 2.9 253,023 1

Sort (cost=1,070,136.60..1,071,958.65 rows=728,819 width=91) (actual time=3,855.821..3,881.485 rows=253,023 loops=1)

  • Sort Key: i.id, boc.id
  • Sort Method: external merge Disk: 24256kB
5. 2,845.195 3,764.075 ↑ 2.9 253,023 1

Nested Loop Left Join (cost=3.82..924,428.12 rows=728,819 width=91) (actual time=0.063..3,764.075 rows=253,023 loops=1)

  • Join Filter: (i.tags @> ARRAY[t.id])
  • Rows Removed by Join Filter: 19378023
6. 42.655 182.563 ↑ 3.0 245,439 1

Hash Left Join (cost=3.82..60,775.62 rows=728,819 width=114) (actual time=0.038..182.563 rows=245,439 loops=1)

  • Hash Cond: (i.bo_class_id = boc.id)
7. 139.885 139.885 ↑ 3.0 245,439 1

Seq Scan on bo_instance i (cost=0.00..58,758.54 rows=728,819 width=105) (actual time=0.008..139.885 rows=245,439 loops=1)

  • Filter: (NOT is_deleted)
  • Rows Removed by Filter: 161
8. 0.012 0.023 ↑ 1.0 81 1

Hash (cost=2.81..2.81 rows=81 width=17) (actual time=0.023..0.023 rows=81 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 12kB
9. 0.011 0.011 ↑ 1.0 81 1

Seq Scan on bo_class boc (cost=0.00..2.81 rows=81 width=17) (actual time=0.002..0.011 rows=81 loops=1)

10. 736.307 736.317 ↑ 1.0 79 245,439

Materialize (cost=0.00..2.19 rows=79 width=17) (actual time=0.000..0.003 rows=79 loops=245,439)

11. 0.010 0.010 ↑ 1.0 79 1

Seq Scan on tag t (cost=0.00..1.79 rows=79 width=17) (actual time=0.005..0.010 rows=79 loops=1)