explain.depesz.com

PostgreSQL's explain analyze made readable

Result: hGIP

Settings
# exclusive inclusive rows x rows loops node
1. 0.143 2.159 ↑ 1.6 94 1

Sort (cost=588.73..589.10 rows=146 width=689) (actual time=2.153..2.159 rows=94 loops=1)

  • Sort Key: srp.start_date DESC
  • Sort Method: quicksort Memory: 38kB
2. 0.325 2.016 ↑ 1.6 94 1

Nested Loop Left Join (cost=2.64..583.49 rows=146 width=689) (actual time=0.227..2.016 rows=94 loops=1)

3. 0.089 0.375 ↑ 1.6 94 1

Hash Join (cost=2.36..7.12 rows=146 width=166) (actual time=0.144..0.375 rows=94 loops=1)

  • Hash Cond: (srp.status_id = dss.shift_status_id)
4. 0.154 0.240 ↑ 1.6 94 1

Hash Join (cost=1.27..5.25 rows=146 width=166) (actual time=0.076..0.240 rows=94 loops=1)

  • Hash Cond: (srp.pos_id = dp.pos_id)
5. 0.053 0.053 ↑ 1.6 94 1

Seq Scan on shift_registry_pos srp (cost=0.00..3.46 rows=146 width=53) (actual time=0.022..0.053 rows=94 loops=1)

6. 0.016 0.033 ↓ 1.1 13 1

Hash (cost=1.12..1.12 rows=12 width=150) (actual time=0.033..0.033 rows=13 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
7. 0.017 0.017 ↓ 1.1 13 1

Seq Scan on dic_pos dp (cost=0.00..1.12 rows=12 width=150) (actual time=0.012..0.017 rows=13 loops=1)

8. 0.022 0.046 ↑ 1.0 4 1

Hash (cost=1.04..1.04 rows=4 width=32) (actual time=0.046..0.046 rows=4 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 9kB
9. 0.024 0.024 ↑ 1.0 4 1

Seq Scan on dic_shift_status dss (cost=0.00..1.04 rows=4 width=32) (actual time=0.022..0.024 rows=4 loops=1)

10. 0.470 0.470 ↑ 1.0 1 94

Index Scan using pk_dic_users_id on dic_user du (cost=0.28..1.45 rows=1 width=17) (actual time=0.005..0.005 rows=1 loops=94)

  • Index Cond: (user_id = srp.closed_by)
11.          

SubPlan (forNested Loop Left Join)

12. 0.846 0.846 ↑ 1.0 1 94

Index Scan using pk_shift_registry on shift_registry sr (cost=0.29..2.50 rows=1 width=10) (actual time=0.009..0.009 rows=1 loops=94)

  • Index Cond: (shift_registry_id = srp.cashdesk_shift_id)