explain.depesz.com

PostgreSQL's explain analyze made readable

Result: Phh4

Settings
# exclusive inclusive rows x rows loops node
1. 0.002 122.726 ↓ 2.5 20 1

Limit (cost=4,612.34..4,612.36 rows=8 width=1,668) (actual time=122.715..122.726 rows=20 loops=1)

  • Buffers: shared hit=21018
2. 2.307 122.724 ↓ 2.5 20 1

Sort (cost=4,612.34..4,612.36 rows=8 width=1,668) (actual time=122.715..122.724 rows=20 loops=1)

  • Sort Key: source_placed_at DESC
  • Sort Method: top-N heapsort Memory: 65kB
  • Buffers: shared hit=21018
3. 120.417 120.417 ↓ 496.8 3,974 1

Index Scan using outletid_sourceplacedat on orders (cost=0.56..4,612.22 rows=8 width=1,668) (actual time=0.064..120.417 rows=3,974 loops=1)

  • Index Cond: (((tags #>> '{outletId}'::text[]) = ANY ('{22628,22636,22637,25987,28236,29726,31020,31021,31232,34406}'::text[])) AND (source_placed_at >= '1581100200000'::bigint) AND (source_placed_at <= '1581618599000'::bigint))
  • Filter: ((tags #>> '{brandId}'::text[]) = '3343'::text)
  • Buffers: shared hit=21018
Planning time : 0.437 ms