explain.depesz.com

PostgreSQL's explain analyze made readable

Result: UAWj

Settings
# exclusive inclusive rows x rows loops node
1. 16.700 137.158 ↓ 1.1 20,236 1

Sort (cost=56,331.46..56,376.86 rows=18,161 width=208) (actual time=135.216..137.158 rows=20,236 loops=1)

  • Sort Key: fr.id
  • Sort Method: external merge Disk: 3272kB
2. 27.334 120.458 ↓ 1.1 20,236 1

WindowAgg (cost=15,741.49..53,990.95 rows=18,161 width=208) (actual time=105.857..120.458 rows=20,236 loops=1)

3. 22.654 93.124 ↓ 1.1 20,236 1

Hash Left Join (cost=15,741.49..53,763.93 rows=18,161 width=200) (actual time=16.534..93.124 rows=20,236 loops=1)

  • Hash Cond: ((fr.product_id = fc.product_id) AND (req.product_context_id = fc.context_id) AND (((fr.filepath '/'::text) fr.filename) = fc.file_name) AND (md5(((fr.filepath '/'::text) f
4. 4.178 63.553 ↓ 1.1 20,236 1

Hash Join (cost=15,347.50..53,165.63 rows=18,161 width=197) (actual time=9.593..63.553 rows=20,236 loops=1)

  • Hash Cond: (fr.request_id = req.id)
5. 4.600 58.049 ↓ 1.1 20,236 1

Nested Loop (cost=15,158.83..52,929.24 rows=18,161 width=189) (actual time=8.256..58.049 rows=20,236 loops=1)

6. 9.515 12.977 ↓ 1.1 20,236 1

HashAggregate (cost=15,158.40..15,340.01 rows=18,161 width=8) (actual time=8.239..12.977 rows=20,236 loops=1)

  • Group Key: latest_file_results.file_results_id
7. 3.462 3.462 ↓ 1.1 20,236 1

Index Scan using latest_file_results_product_context_id_ix on latest_file_results (cost=0.43..15,113.00 rows=18,161 width=8) (actual time=0.044..3.462 rows=20,236 loops=1)

  • Index Cond: (product_context_id = 464)
8. 40.472 40.472 ↑ 1.0 1 20,236

Index Scan using file_results_pkey on file_results fr (cost=0.43..2.08 rows=1 width=189) (actual time=0.002..0.002 rows=1 loops=20,236)

  • Index Cond: (id = latest_file_results.file_results_id)
9. 0.361 1.326 ↓ 1.0 3,619 1

Hash (cost=143.85..143.85 rows=3,585 width=16) (actual time=1.326..1.326 rows=3,619 loops=1)

  • Buckets: 4096 Batches: 1 Memory Usage: 202kB
10. 0.965 0.965 ↓ 1.0 3,619 1

Seq Scan on scan_requests req (cost=0.00..143.85 rows=3,585 width=16) (actual time=0.012..0.965 rows=3,619 loops=1)

11. 5.510 6.917 ↑ 1.0 7,733 1

Hash (cost=239.33..239.33 rows=7,733 width=124) (actual time=6.917..6.917 rows=7,733 loops=1)

  • Buckets: 8192 Batches: 1 Memory Usage: 1290kB
12. 1.407 1.407 ↑ 1.0 7,733 1

Seq Scan on file_comments fc (cost=0.00..239.33 rows=7,733 width=124) (actual time=0.009..1.407 rows=7,733 loops=1)