explain.depesz.com

PostgreSQL's explain analyze made readable

Result: FZNC

Settings
# exclusive inclusive rows x rows loops node
1. 2,411.197 99,155.876 ↑ 1.0 6,075,468 1

Unique (cost=11,153,510.34..11,215,710.61 rows=6,220,027 width=1,673) (actual time=83,121.349..99,155.876 rows=6,075,468 loops=1)

2. 72,784.386 96,744.679 ↓ 1.0 6,291,382 1

Sort (cost=11,153,510.34..11,169,060.41 rows=6,220,027 width=1,673) (actual time=83,121.348..96,744.679 rows=6,291,382 loops=1)

  • Sort Key: fa.dynamic_flight_group_key, p.ap_id, p.room_group, (CASE WHEN (fa.markup_type = 'PREMIUM'::text) THEN ((((p.price_current)::numeric + ('2'::numeric * COALESCE(fa.adult_price, '0'::numeric))) + ('0'::numeric * COALESCE(fa.child_price, '0'::numeric))))::integer ELSE ((p.price_current + (2 * COALESCE(fa.adult_markup, 0))) + (0 * COALESCE(fa.child_markup, 0))) END)
  • Sort Method: external merge Disk: 4136184kB
3. 19,294.767 23,960.293 ↓ 1.0 6,291,382 1

Hash Join (cost=62,639.41..1,394,922.28 rows=6,220,027 width=1,673) (actual time=442.182..23,960.293 rows=6,291,382 loops=1)

  • Hash Cond: (p.flight_group_key = fa.flight_group_key)
4. 4,223.449 4,223.449 ↓ 3.3 7,820,154 1

Seq Scan on prices_1100 p (cost=0.00..625,612.00 rows=2,406,200 width=969) (actual time=0.012..4,223.449 rows=7,820,154 loops=1)

5. 315.913 442.077 ↓ 1,140.2 589,469 1

Hash (cost=62,632.95..62,632.95 rows=517 width=1,180) (actual time=442.077..442.077 rows=589,469 loops=1)

  • Buckets: 131072 (originally 1024) Batches: 8 (originally 1) Memory Usage: 38977kB
6. 0.000 126.164 ↓ 1,140.2 589,469 1

Gather (cost=1,000.00..62,632.95 rows=517 width=1,180) (actual time=3.333..126.164 rows=589,469 loops=1)

  • Workers Planned: 2
  • Workers Launched: 2
7. 167.678 167.678 ↓ 913.9 196,490 3

Parallel Seq Scan on flights_all fa (cost=0.00..61,581.25 rows=215 width=1,180) (actual time=1.148..167.678 rows=196,490 loops=3)

  • Filter: (d3pf AND (seats >= 2) AND (stay = (bedbanks_nights + 1)))
  • Rows Removed by Filter: 10379