explain.depesz.com

PostgreSQL's explain analyze made readable

Result: WM1

Settings

Optimization(s) for this plan:

# exclusive inclusive rows x rows loops node
1. 0.603 146.737 ↓ 1.0 392 1

Nested Loop Left Join (cost=231.86..71,592.11 rows=391 width=345) (actual time=0.538..146.737 rows=392 loops=1)

2. 0.154 0.310 ↓ 1.0 392 1

Hash Left Join (cost=52.64..1,502.12 rows=391 width=111) (actual time=0.065..0.310 rows=392 loops=1)

  • Hash Cond: (wifiaeroscouttags.wat_mac = wifiaeroscouttagsassignmenthistory.watah_mac)
3. 0.107 0.129 ↓ 1.0 392 1

Bitmap Heap Scan on wifiaeroscouttags (cost=22.33..1,470.33 rows=391 width=7) (actual time=0.031..0.129 rows=392 loops=1)

  • Recheck Cond: (wat_active IS TRUE)
  • Heap Blocks: exact=12
4. 0.022 0.022 ↓ 1.0 392 1

Bitmap Index Scan on wat_active_mac (cost=0.00..22.23 rows=391 width=0) (actual time=0.022..0.022 rows=392 loops=1)

5. 0.001 0.027 ↑ 8.0 1 1

Hash (cost=30.21..30.21 rows=8 width=110) (actual time=0.027..0.027 rows=1 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
6. 0.002 0.026 ↑ 8.0 1 1

Nested Loop (cost=14.57..30.21 rows=8 width=110) (actual time=0.025..0.026 rows=1 loops=1)

7. 0.006 0.017 ↑ 8.0 1 1

Hash Join (cost=14.42..26.95 rows=8 width=82) (actual time=0.016..0.017 rows=1 loops=1)

  • Hash Cond: (nodeslogical.nl_id = wifiaeroscouttagsassignmenthistory.watah_nl_id)
8. 0.004 0.004 ↑ 40.0 5 1

Seq Scan on nodeslogical (cost=0.00..12.00 rows=200 width=72) (actual time=0.003..0.004 rows=5 loops=1)

9. 0.003 0.007 ↑ 8.0 1 1

Hash (cost=14.32..14.32 rows=8 width=18) (actual time=0.007..0.007 rows=1 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
10. 0.002 0.004 ↑ 8.0 1 1

Bitmap Heap Scan on wifiaeroscouttagsassignmenthistory (cost=4.19..14.32 rows=8 width=18) (actual time=0.004..0.004 rows=1 loops=1)

  • Recheck Cond: (watah_end IS NULL)
  • Heap Blocks: exact=1
11. 0.002 0.002 ↑ 8.0 1 1

Bitmap Index Scan on watah_unique_active_logical (cost=0.00..4.18 rows=8 width=0) (actual time=0.002..0.002 rows=1 loops=1)

12. 0.007 0.007 ↑ 1.0 1 1

Index Scan using entities_pkey on entities (cost=0.15..0.41 rows=1 width=36) (actual time=0.007..0.007 rows=1 loops=1)

  • Index Cond: (e_id = nodeslogical.nl_e_id)
13. 0.392 145.824 ↑ 1.0 1 392

Limit (cost=179.22..179.23 rows=1 width=185) (actual time=0.371..0.372 rows=1 loops=392)

14. 1.568 145.432 ↑ 1.0 1 392

Sort (cost=179.22..179.23 rows=1 width=185) (actual time=0.371..0.371 rows=1 loops=392)

  • Sort Key: wifiaeroscouttagspositionhistory.watph_from DESC
  • Sort Method: top-N heapsort Memory: 25kB
15. 4.704 143.864 ↓ 15.0 15 392

Nested Loop Left Join (cost=44.25..179.21 rows=1 width=185) (actual time=0.084..0.367 rows=15 loops=392)

16. 0.000 139.160 ↓ 15.0 15 392

Nested Loop Left Join (cost=44.11..179.02 rows=1 width=35) (actual time=0.083..0.355 rows=15 loops=392)

17. 1.540 133.672 ↓ 15.0 15 392

Hash Left Join (cost=43.98..178.85 rows=1 width=32) (actual time=0.082..0.341 rows=15 loops=392)

  • Hash Cond: (wifiaeroscouttagspositionhistory.watph_wap_basemac = wifiaccesspointsassignmenthistory.wapah_basemac)
  • Filter: (wifiaccesspointsassignmenthistory.wapah_end IS NULL)
18. 132.104 132.104 ↓ 1.9 15 392

Seq Scan on wifiaeroscouttagspositionhistory (cost=0.00..132.85 rows=8 width=22) (actual time=0.082..0.337 rows=15 loops=392)

  • Filter: (watph_wat_mac = wifiaeroscouttags.wat_mac)
  • Rows Removed by Filter: 6088
19. 0.018 0.028 ↑ 503.3 3 1

Hash (cost=25.10..25.10 rows=1,510 width=18) (actual time=0.004..0.028 rows=3 loops=1)

  • Buckets: 2048 Batches: 1 Memory Usage: 17kB
20. 0.010 0.010 ↑ 503.3 3 1

Seq Scan on wifiaccesspointsassignmenthistory (cost=0.00..25.10 rows=1,510 width=18) (actual time=0.002..0.010 rows=3 loops=1)

21. 5.697 5.697 ↑ 1.0 1 5,697

Index Scan using wifiaccesspoints_pkey on wifiaccesspoints (cost=0.13..0.16 rows=1 width=15) (actual time=0.001..0.001 rows=1 loops=5,697)

  • Index Cond: (wap_basemac = wifiaccesspointsassignmenthistory.wapah_basemac)
22. 0.000 0.000 ↑ 1.0 1 5,697

Index Scan using nodeslogical_pkey on nodeslogical nodeslogical_1 (cost=0.14..0.19 rows=1 width=158) (actual time=0.000..0.000 rows=1 loops=5,697)

  • Index Cond: (nl_id = wifiaccesspointsassignmenthistory.wapah_nl_id)