explain.depesz.com

PostgreSQL's explain analyze made readable

Result: i31b

Settings
# exclusive inclusive rows x rows loops node
1. 0.000 0.000 ↓ 0.0

Hash Join (cost=122.75..1,098,507.17 rows=500,480 width=48) (actual rows= loops=)

  • Output: m.ts, r.series, m.val
  • Hash Cond: (m.shash = r.shash)
2. 0.000 0.000 ↓ 0.0

Append (cost=100.00..1,080,717.38 rows=100,096 width=24) (actual rows= loops=)

3. 0.000 0.000 ↓ 0.0

Foreign Scan on public.metrics_shard_0 m (cost=100.00..179,748.15 rows=16,656 width=24) (actual rows= loops=)

  • Output: m.ts, m.val, m.shash
  • Filter: ((m.ts <= now()) AND (m.ts >= (now() - '365 days'::interval)))
  • Remote SQL: SELECT ts, shash, val FROM public.metrics_dn_0_shard_0
4. 0.000 0.000 ↓ 0.0

Foreign Scan on public.metrics_shard_1 m_1 (cost=100.00..181,687.15 rows=16,836 width=24) (actual rows= loops=)

  • Output: m_1.ts, m_1.val, m_1.shash
  • Filter: ((m_1.ts <= now()) AND (m_1.ts >= (now() - '365 days'::interval)))
  • Remote SQL: SELECT ts, shash, val FROM public.metrics_dn_0_shard_1
5. 0.000 0.000 ↓ 0.0

Foreign Scan on public.metrics_shard_2 m_2 (cost=100.00..170,482.15 rows=15,796 width=24) (actual rows= loops=)

  • Output: m_2.ts, m_2.val, m_2.shash
  • Filter: ((m_2.ts <= now()) AND (m_2.ts >= (now() - '365 days'::interval)))
  • Remote SQL: SELECT ts, shash, val FROM public.metrics_dn_1_shard_0
6. 0.000 0.000 ↓ 0.0

Foreign Scan on public.metrics_shard_3 m_3 (cost=100.00..176,085.15 rows=16,316 width=24) (actual rows= loops=)

  • Output: m_3.ts, m_3.val, m_3.shash
  • Filter: ((m_3.ts <= now()) AND (m_3.ts >= (now() - '365 days'::interval)))
  • Remote SQL: SELECT ts, shash, val FROM public.metrics_dn_1_shard_1
7. 0.000 0.000 ↓ 0.0

Foreign Scan on public.metrics_shard_4 m_4 (cost=100.00..183,839.15 rows=17,036 width=24) (actual rows= loops=)

  • Output: m_4.ts, m_4.val, m_4.shash
  • Filter: ((m_4.ts <= now()) AND (m_4.ts >= (now() - '365 days'::interval)))
  • Remote SQL: SELECT ts, shash, val FROM public.metrics_dn_2_shard_0
8. 0.000 0.000 ↓ 0.0

Foreign Scan on public.metrics_shard_5 m_5 (cost=100.00..188,375.15 rows=17,456 width=24) (actual rows= loops=)

  • Output: m_5.ts, m_5.val, m_5.shash
  • Filter: ((m_5.ts <= now()) AND (m_5.ts >= (now() - '365 days'::interval)))
  • Remote SQL: SELECT ts, shash, val FROM public.metrics_dn_2_shard_1
9. 0.000 0.000 ↓ 0.0

Hash (cost=10.25..10.25 rows=1,000 width=40) (actual rows= loops=)

  • Output: r.series, r.shash
10. 0.000 0.000 ↓ 0.0

Function Scan on public.lookup r (cost=0.25..10.25 rows=1,000 width=40) (actual rows= loops=)

  • Output: r.series, r.shash
  • Function Call: lookup('yellow_sky'::text, 'hidden_holy_bar_660'::text, VARIADIC '{cluster,holy_noisy_raspy_wave}'::text[])