explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 75Lg

Settings
# exclusive inclusive rows x rows loops node
1. 80.991 42,554.672 ↑ 8.6 45,901 1

Hash Join (cost=6,969.62..49,307.38 rows=395,185 width=43) (actual time=56.314..42,554.672 rows=45,901 loops=1)

  • Hash Cond: (b.security_id = its_universe_component.m_security_id)
2.          

CTE timestamps

3. 0.079 0.079 ↑ 1.0 28 1

Values Scan on "*VALUES*" (cost=0.00..0.35 rows=28 width=8) (actual time=0.001..0.079 rows=28 loops=1)

4. 73.750 42,418.332 ↓ 1.3 519,975 1

Nested Loop (cost=0.56..41,300.77 rows=395,185 width=43) (actual time=0.923..42,418.332 rows=519,975 loops=1)

5. 0.126 0.126 ↑ 1.0 28 1

CTE Scan on timestamps (cost=0.00..0.56 rows=28 width=8) (actual time=0.002..0.126 rows=28 loops=1)

6. 42,344.456 42,344.456 ↓ 1.3 18,571 28

Index Scan using ts_marketcap_instrument_pkey on ts_marketcap_instrument b (cost=0.56..1,333.87 rows=14,114 width=43) (actual time=0.466..1,512.302 rows=18,571 loops=28)

  • Index Cond: ("timestamp" = timestamps.ts)
7. 0.360 55.349 ↑ 11.0 2,086 1

Hash (cost=6,680.98..6,680.98 rows=23,018 width=8) (actual time=55.349..55.349 rows=2,086 loops=1)

  • Buckets: 32,768 Batches: 1 Memory Usage: 338kB
8. 31.092 54.989 ↑ 11.0 2,086 1

HashAggregate (cost=6,220.62..6,450.80 rows=23,018 width=8) (actual time=54.630..54.989 rows=2,086 loops=1)

  • Group Key: its_universe_component.m_security_id
9. 23.897 23.897 ↑ 1.0 282,841 1

Index Only Scan using its_universe_component_idx_universe_id_covering on its_universe_component (cost=0.44..5,492.30 rows=291,330 width=8) (actual time=0.016..23.897 rows=282,841 loops=1)

  • Index Cond: (m_universe_id = 154)
  • Heap Fetches: 0