explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 81pO

Settings
# exclusive inclusive rows x rows loops node
1. 0.060 2,217.027 ↓ 9.0 18 1

Sort (cost=458,904.49..458,904.49 rows=2 width=11) (actual time=2,217.013..2,217.027 rows=18 loops=1)

  • Sort Key: (count(cdr_channels.cdr_channel_id))
  • Sort Method: quicksort Memory: 25kB
  • Buffers: shared hit=286768
2. 1.856 2,216.967 ↓ 9.0 18 1

HashAggregate (cost=458,904.46..458,904.48 rows=2 width=11) (actual time=2,216.962..2,216.967 rows=18 loops=1)

  • Group Key: cdr_channels.endpoint
  • Buffers: shared hit=286768
3. 60.659 2,215.111 ↓ 15.2 4,608 1

Hash Join (cost=192,680.12..458,902.94 rows=303 width=11) (actual time=2,121.974..2,215.111 rows=4,608 loops=1)

  • Hash Cond: ((cdr_channels.linkedid)::text = (cdr_channels_1.linkedid)::text)
  • Buffers: shared hit=286768
4. 1,328.825 1,328.825 ↓ 11.7 59,299 1

Seq Scan on cdr_channels (cost=0.00..266,177.87 rows=5,068 width=30) (actual time=0.579..1,328.825 rows=59,299 loops=1)

  • Filter: (is_agent AND (bill_sec > 10) AND ((endpoint)::text = ANY ('{73076,73725,73936,73410,71171,74769,73617,74095,75017,73178,71189,73952,73361,75486,75937,73772,73228,73026,71174,73744,73457,75625,73006,77018,75061}'::text[])))
  • Rows Removed by Filter: 2725841
  • Buffers: shared hit=143384
5. 5.842 825.627 ↓ 3.4 16,912 1

Hash (cost=192,618.65..192,618.65 rows=4,918 width=19) (actual time=825.627..825.627 rows=16,912 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 843kB
  • Buffers: shared hit=143384
6. 14.439 819.785 ↓ 3.4 16,912 1

HashAggregate (cost=192,569.47..192,618.65 rows=4,918 width=19) (actual time=814.498..819.785 rows=16,912 loops=1)

  • Group Key: (cdr_channels_1.linkedid)::text
  • Buffers: shared hit=143384
7. 805.346 805.346 ↑ 1.6 16,912 1

Seq Scan on cdr_channels cdr_channels_1 (cost=0.00..192,501.55 rows=27,167 width=19) (actual time=710.568..805.346 rows=16,912 loops=1)

  • Filter: ((begin_date >= '2019-05-01 00:00:00+00'::timestamp with time zone) AND (begin_date <= '2019-06-01 00:00:00+00'::timestamp with time zone) AND ((chan_src)::text = 'external'::text))
  • Rows Removed by Filter: 2768228
  • Buffers: shared hit=143384