explain.depesz.com

PostgreSQL's explain analyze made readable

Result: FoCaB

Settings
# exclusive inclusive rows x rows loops node
1. 0.003 0.204 ↓ 2.0 2 1

Nested Loop (cost=454.23..547.52 rows=1 width=259) (actual time=0.188..0.204 rows=2 loops=1)

  • Buffers: shared hit=23
2. 0.004 0.129 ↑ 7.0 3 1

HashAggregate (cost=453.81..454.01 rows=21 width=4) (actual time=0.129..0.129 rows=3 loops=1)

  • Group Key: namespaces.id
  • Buffers: shared hit=12
3. 0.125 0.125 ↑ 7.0 3 1

CTE Scan on base_and_ancestors namespaces (cost=453.12..453.54 rows=21 width=4) (actual time=0.050..0.125 rows=3 loops=1)

  • Buffers: shared hit=12
4.          

CTE base_and_ancestors

5. 0.027 0.121 ↑ 7.0 3 1

Recursive Union (cost=0.43..453.12 rows=21 width=323) (actual time=0.048..0.121 rows=3 loops=1)

  • Buffers: shared hit=12
6. 0.034 0.034 ↑ 1.0 1 1

Index Scan using namespaces_pkey on public.namespaces namespaces_1 (cost=0.43..4.45 rows=1 width=323) (actual time=0.034..0.034 rows=1 loops=1)

  • Index Cond: (namespaces_1.id = 4006638)
  • Filter: ((namespaces_1.type)::text = 'Group'::text)
  • Rows Removed by Filter: 0
  • Buffers: shared hit=4
7. 0.006 0.060 ↑ 2.0 1 3

Nested Loop (cost=0.43..44.83 rows=2 width=323) (actual time=0.020..0.020 rows=1 loops=3)

  • Buffers: shared hit=8
8. 0.000 0.000 ↑ 10.0 1 3

WorkTable Scan on base_and_ancestors (cost=0.00..0.20 rows=10 width=4) (actual time=0.000..0.000 rows=1 loops=3)

9. 0.054 0.054 ↑ 1.0 1 3

Index Scan using namespaces_pkey on public.namespaces namespaces_2 (cost=0.43..4.45 rows=1 width=323) (actual time=0.018..0.018 rows=1 loops=3)

  • Index Cond: (namespaces_2.id = base_and_ancestors.parent_id)
  • Filter: ((namespaces_2.type)::text = 'Group'::text)
  • Rows Removed by Filter: 0
  • Buffers: shared hit=8
10. 0.072 0.072 ↑ 1.0 1 3

Index Scan using i1 on public.web_hooks (cost=0.42..4.44 rows=1 width=259) (actual time=0.019..0.024 rows=1 loops=3)

  • Index Cond: (web_hooks.group_id = namespaces.id)
  • Filter: ((web_hooks.type)::text = 'GroupHook'::text)
  • Rows Removed by Filter: 0
  • Buffers: shared hit=11