explain.depesz.com

PostgreSQL's explain analyze made readable

Result: EZyN : First query

Settings
# exclusive inclusive rows x rows loops node
1. 0.082 104.715 ↑ 1.0 101 1

Sort (cost=5,898.88..5,899.14 rows=104 width=76) (actual time=104.709..104.715 rows=101 loops=1)

  • Sort Key: (count(fl.*)) DESC
  • Sort Method: quicksort Memory: 33kB
2. 0.184 104.633 ↑ 1.0 101 1

WindowAgg (cost=5,883.00..5,895.40 rows=104 width=76) (actual time=104.526..104.633 rows=101 loops=1)

3. 0.141 104.449 ↑ 1.0 101 1

GroupAggregate (cost=5,883.00..5,891.76 rows=104 width=44) (actual time=104.280..104.449 rows=101 loops=1)

  • Group Key: ((ap.airport_name ->> 'ru'::text))
4. 0.833 104.308 ↑ 1.1 541 1

Sort (cost=5,883.00..5,884.49 rows=597 width=119) (actual time=104.266..104.308 rows=541 loops=1)

  • Sort Key: ((ap.airport_name ->> 'ru'::text))
  • Sort Method: quicksort Memory: 128kB
5. 0.853 103.475 ↑ 1.1 541 1

Hash Join (cost=5.34..5,855.47 rows=597 width=119) (actual time=0.564..103.475 rows=541 loops=1)

  • Hash Cond: (fl.departure_airport = ap.airport_code)
6. 102.538 102.538 ↑ 1.1 541 1

Seq Scan on flights fl (cost=0.00..5,847.00 rows=597 width=91) (actual time=0.426..102.538 rows=541 loops=1)

  • Filter: (actual_departure > ('2017-08-15 18:00:00+03'::timestamp with time zone - '1 day'::interval))
  • Rows Removed by Filter: 214326
7. 0.040 0.084 ↑ 1.0 104 1

Hash (cost=4.04..4.04 rows=104 width=65) (actual time=0.084..0.084 rows=104 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 18kB
8. 0.044 0.044 ↑ 1.0 104 1

Seq Scan on airports_data ap (cost=0.00..4.04 rows=104 width=65) (actual time=0.015..0.044 rows=104 loops=1)