explain.depesz.com

PostgreSQL's explain analyze made readable

Result: XSa1

Settings
# exclusive inclusive rows x rows loops node
1. 108.935 447.106 ↑ 5.8 620 1

GroupAggregate (cost=91,614.01..93,496.38 rows=3,568 width=110) (actual time=327.298..447.106 rows=620 loops=1)

  • Group Key: query.date, query."s.geo_country_code
2. 60.189 338.171 ↓ 2.6 92,899 1

Sort (cost=91,614.01..91,703.23 rows=35,685 width=106) (actual time=327.143..338.171 rows=92,899 loops=1)

  • Sort Key: query.date, query."s.geo_country_code
  • Sort Method: quicksort Memory: 16136kB
3. 15.372 277.982 ↓ 2.6 92,899 1

Subquery Scan on query (cost=87,755.93..88,915.69 rows=35,685 width=106) (actual time=187.365..277.982 rows=92,899 loops=1)

4. 65.139 262.610 ↓ 2.6 92,899 1

WindowAgg (cost=87,755.93..88,558.84 rows=35,685 width=114) (actual time=187.364..262.610 rows=92,899 loops=1)

5. 57.195 197.471 ↓ 2.6 92,899 1

Sort (cost=87,755.93..87,845.14 rows=35,685 width=98) (actual time=187.344..197.471 rows=92,899 loops=1)

  • Sort Key: p.id
  • Sort Method: quicksort Memory: 16136kB
6. 27.892 140.276 ↓ 2.6 92,899 1

Hash Join (cost=76,417.06..85,057.60 rows=35,685 width=98) (actual time=81.606..140.276 rows=92,899 loops=1)

  • Hash Cond: (p.session_id = s.id)
7. 23.992 111.175 ↓ 12.3 92,899 1

Hash Join (cost=75,663.14..83,038.70 rows=7,568 width=88) (actual time=80.391..111.175 rows=92,899 loops=1)

  • Hash Cond: (p.id = e.page_view_id)
8. 1.096 7.507 ↑ 1.0 9,290 1

Append (cost=0.00..7,264.60 rows=9,406 width=36) (actual time=0.024..7.507 rows=9,290 loops=1)

9. 0.005 0.005 ↓ 0.0 0 1

Seq Scan on stats_page_view p (cost=0.00..0.00 rows=1 width=36) (actual time=0.004..0.005 rows=0 loops=1)

  • Filter: ((created_at >= '2019-04-01 00:00:00+00'::timestamp with time zone) AND (created_at <= '2019-04-10 23:59:59+00'::timestamp with time zone) AND (property_id = 2))
10. 6.406 6.406 ↑ 1.0 9,290 1

Index Scan using _hyper_3_3_chunk_idx_pageview_property_id_and_created_at on _hyper_3_3_chunk p_1 (cost=0.42..7,217.57 rows=9,405 width=36) (actual time=0.019..6.406 rows=9,290 loops=1)

  • Index Cond: ((property_id = 2) AND (created_at >= '2019-04-01 00:00:00+00'::timestamp with time zone) AND (created_at <= '2019-04-10 23:59:59+00'::timestamp with time zone))
11. 22.560 79.676 ↑ 1.1 92,899 1

Hash (cost=74,407.29..74,407.29 rows=100,468 width=68) (actual time=79.676..79.676 rows=92,899 loops=1)

  • Buckets: 131072 Batches: 1 Memory Usage: 7194kB
12. 9.259 57.116 ↑ 1.1 92,899 1

Append (cost=0.00..74,407.29 rows=100,468 width=68) (actual time=0.024..57.116 rows=92,899 loops=1)

13. 0.005 0.005 ↓ 0.0 0 1

Seq Scan on stats_event e (cost=0.00..0.00 rows=1 width=68) (actual time=0.004..0.005 rows=0 loops=1)

  • Filter: ((created_at >= '2019-04-01 00:00:00+00'::timestamp with time zone) AND (created_at <= '2019-04-10 23:59:59+00'::timestamp with time zone) AND (property_id = 2))
14. 47.852 47.852 ↑ 1.1 92,899 1

Index Scan using _hyper_5_4_chunk_idx_event_property_id_and_created_at on _hyper_5_4_chunk e_1 (cost=0.43..73,904.95 rows=100,467 width=68) (actual time=0.019..47.852 rows=92,899 loops=1)

  • Index Cond: ((property_id = 2) AND (created_at >= '2019-04-01 00:00:00+00'::timestamp with time zone) AND (created_at <= '2019-04-10 23:59:59+00'::timestamp with time zone))
15. 0.193 1.209 ↑ 1.0 929 1

Hash (cost=742.13..742.13 rows=943 width=26) (actual time=1.209..1.209 rows=929 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 61kB
16. 0.092 1.016 ↑ 1.0 929 1

Append (cost=0.00..742.13 rows=943 width=26) (actual time=0.019..1.016 rows=929 loops=1)

17. 0.005 0.005 ↓ 0.0 0 1

Seq Scan on stats_session s (cost=0.00..0.00 rows=1 width=62) (actual time=0.005..0.005 rows=0 loops=1)

  • Filter: ((created_at >= '2019-04-01 00:00:00+00'::timestamp with time zone) AND (created_at <= '2019-04-10 23:59:59+00'::timestamp with time zone) AND (property_id = 2))
18. 0.919 0.919 ↑ 1.0 929 1

Index Scan using _hyper_2_2_chunk_idx_session_property_id_and_created_at on _hyper_2_2_chunk s_1 (cost=0.29..737.41 rows=942 width=26) (actual time=0.013..0.919 rows=929 loops=1)

  • Index Cond: ((property_id = 2) AND (created_at >= '2019-04-01 00:00:00+00'::timestamp with time zone) AND (created_at <= '2019-04-10 23:59:59+00'::timestamp with time zone))