explain.depesz.com

PostgreSQL's explain analyze made readable

Result: gH03

Settings
# exclusive inclusive rows x rows loops node
1. 0.011 1,580.267 ↑ 1.0 100 1

Limit (cost=107,073.60..107,073.85 rows=100 width=74) (actual time=1,580.253..1,580.267 rows=100 loops=1)

2. 79.759 1,580.256 ↑ 4,821.7 100 1

Sort (cost=107,073.60..108,279.02 rows=482,171 width=74) (actual time=1,580.251..1,580.256 rows=100 loops=1)

  • Sort Key: (max(factual_report_subscore.subscore_value))
  • Sort Method: top-N heapsort Memory: 48kB
3. 400.661 1,500.497 ↓ 1.0 482,231 1

HashAggregate (cost=83,823.66..88,645.37 rows=482,171 width=74) (actual time=1,386.425..1,500.497 rows=482,231 loops=1)

  • Group Key: fr.id
4. 283.981 1,099.836 ↑ 1.0 910,916 1

Hash Semi Join (cost=43,919.69..79,262.01 rows=912,330 width=74) (actual time=385.837..1,099.836 rows=910,916 loops=1)

  • Hash Cond: ((fr.id)::text = (factual_report_permission.factual_report_id)::text)
5. 346.677 657.976 ↑ 1.0 910,920 1

Hash Join (cost=26,866.04..49,663.82 rows=912,330 width=99) (actual time=226.614..657.976 rows=910,920 loops=1)

  • Hash Cond: ((factual_report_subscore.factual_report_id)::text = (fr.id)::text)
6. 85.723 85.723 ↓ 1.0 912,418 1

Seq Scan on factual_report_subscore (cost=0.00..20,402.77 rows=912,377 width=33) (actual time=0.005..85.723 rows=912,418 loops=1)

7. 119.232 225.576 ↓ 1.0 482,232 1

Hash (cost=20,838.90..20,838.90 rows=482,171 width=66) (actual time=225.575..225.576 rows=482,232 loops=1)

  • Buckets: 524288 Batches: 1 Memory Usage: 53073kB
8. 106.344 106.344 ↓ 1.0 482,232 1

Seq Scan on factual_report fr (cost=0.00..20,838.90 rows=482,171 width=66) (actual time=0.009..106.344 rows=482,232 loops=1)

  • Filter: ((epicenter_lat >= '-56.2999999999999972'::double precision) AND (epicenter_lat <= '72.0999999999999943'::double precision) AND (epicenter_long >= '-179'::double precision) AND (epicenter_long <= '179'::double precision) AND (valid_to >= '2003-01-01 08:57:01'::timestamp without time zone) AND (valid_from <= '2019-10-22 09:27:01'::timestamp without time zone))
9. 91.764 157.879 ↑ 1.0 482,231 1

Hash (cost=11,024.33..11,024.33 rows=482,346 width=25) (actual time=157.878..157.879 rows=482,231 loops=1)

  • Buckets: 524288 Batches: 1 Memory Usage: 30939kB
10. 66.115 66.115 ↑ 1.0 482,231 1

Seq Scan on factual_report_permission (cost=0.00..11,024.33 rows=482,346 width=25) (actual time=0.015..66.115 rows=482,231 loops=1)

  • Filter: ((organization_id)::text = '59087ebe6acef17ef317c5c8'::text)
Planning time : 2.563 ms
Execution time : 1,582.921 ms