explain.depesz.com

PostgreSQL's explain analyze made readable

Result: TXyi

Settings
# exclusive inclusive rows x rows loops node
1. 0.001 1.021 ↓ 0.0 0 1

GroupAggregate (cost=0.85..21,780.55 rows=3 width=126) (actual time=1.021..1.021 rows=0 loops=1)

  • Group Key: org.name
2. 0.000 1.020 ↓ 0.0 0 1

Nested Loop (cost=0.85..21,780.50 rows=3 width=122) (actual time=1.020..1.020 rows=0 loops=1)

  • Join Filter: (usage_fact.app_id = app_dim.id)
3. 0.006 0.006 ↑ 1.0 1 1

Seq Scan on app_dim (cost=0.00..1.05 rows=1 width=4) (actual time=0.005..0.006 rows=1 loops=1)

  • Filter: ((app)::text = 'TM'::text)
  • Rows Removed by Filter: 3
4. 0.002 1.014 ↓ 0.0 0 1

Nested Loop (cost=0.85..21,779.30 rows=12 width=126) (actual time=1.014..1.014 rows=0 loops=1)

5. 0.108 0.108 ↑ 4.0 1 1

Seq Scan on organisation org (cost=0.00..29.20 rows=4 width=122) (actual time=0.078..0.108 rows=1 loops=1)

  • Filter: ((name)::text = 'Hertfordshire'::text)
  • Rows Removed by Filter: 675
6. 0.022 0.904 ↓ 0.0 0 1

Nested Loop (cost=0.85..5,427.69 rows=984 width=12) (actual time=0.904..0.904 rows=0 loops=1)

7. 0.112 0.112 ↓ 1.2 385 1

Index Scan using idx_date_dim_1 on date_dim (cost=0.42..17.98 rows=328 width=8) (actual time=0.034..0.112 rows=385 loops=1)

  • Index Cond: ((date >= '2020-05-01 00:00:00'::timestamp without time zone) AND (date <= '2020-05-05 00:00:00'::timestamp without time zone))
8. 0.770 0.770 ↓ 0.0 0 385

Index Scan using idx_usage_fact_org_date_id on usage_fact (cost=0.43..16.46 rows=3 width=36) (actual time=0.002..0.002 rows=0 loops=385)

  • Index Cond: ((org_id = org.organisation_id) AND (date_id = date_dim.date_id))
Planning time : 0.471 ms
Execution time : 1.072 ms