explain.depesz.com

PostgreSQL's explain analyze made readable

Result: 9iKk

Settings
# exclusive inclusive rows x rows loops node
1. 8.117 87,128.432 ↑ 41.0 1 1

Nested Loop Left Join (cost=8,113.67..3,859,767.79 rows=41 width=1,711) (actual time=72,666.693..87,128.432 rows=1 loops=1)

2. 2,012.539 87,120.218 ↑ 2.0 1 1

Hash Semi Join (cost=7,974.77..3,859,190.26 rows=2 width=1,395) (actual time=72,658.479..87,120.218 rows=1 loops=1)

  • Hash Cond: (wn.id = t_work_note_answ.id_note)
3. 11,257.874 85,107.653 ↑ 1.5 13,363,592 1

Hash Left Join (cost=7,971.19..3,806,906.41 rows=19,916,292 width=1,395) (actual time=133.681..85,107.653 rows=13,363,592 loops=1)

  • Hash Cond: (wn.id_worker = w_user.id)
4. 6,118.222 73,761.337 ↑ 1.5 13,363,592 1

Hash Left Join (cost=3,774.39..3,711,091.34 rows=19,916,292 width=1,245) (actual time=45.151..73,761.337 rows=13,363,592 loops=1)

  • Hash Cond: (wn.id_reason = st.id)
5. 7,188.382 67,634.694 ↑ 1.5 13,363,592 1

Hash Left Join (cost=3,486.10..3,658,521.73 rows=19,916,292 width=1,184) (actual time=36.680..67,634.694 rows=13,363,592 loops=1)

  • Hash Cond: (wn.id_base_target = bt.id)
6. 7,334.301 60,443.563 ↑ 1.5 13,363,592 1

Hash Left Join (cost=3,365.15..3,606,113.21 rows=19,916,292 width=1,151) (actual time=33.899..60,443.563 rows=13,363,592 loops=1)

  • Hash Cond: (wn.id_note_type = wt.id)
7. 7,300.489 53,109.010 ↑ 1.5 13,363,592 1

Hash Left Join (cost=3,355.13..3,553,636.52 rows=19,916,292 width=1,098) (actual time=33.622..53,109.010 rows=13,363,592 loops=1)

  • Hash Cond: (wn.id_base = b.id)
8. 12,337.528 45,805.304 ↑ 1.5 13,363,592 1

Hash Left Join (cost=3,234.18..3,501,227.97 rows=19,916,292 width=1,065) (actual time=30.365..45,805.304 rows=13,363,592 loops=1)

  • Hash Cond: (wn.id_user_target = w.id)
9. 33,437.551 33,437.551 ↑ 1.5 13,363,592 1

Seq Scan on t_work_note wn (cost=0.00..3,445,712.29 rows=19,916,292 width=1,005) (actual time=0.029..33,437.551 rows=13,363,592 loops=1)

10. 10.444 30.225 ↓ 1.0 30,044 1

Hash (cost=3,129.04..3,129.04 rows=30,041 width=64) (actual time=30.225..30.225 rows=30,044 loops=1)

  • Buckets: 32,768 Batches: 1 Memory Usage: 3,125kB
11. 19.781 19.781 ↓ 1.0 30,044 1

Seq Scan on t_workers w (cost=0.00..3,129.04 rows=30,041 width=64) (actual time=0.009..19.781 rows=30,044 loops=1)

12. 1.574 3.217 ↑ 1.0 5,721 1

Hash (cost=100.77..100.77 rows=5,766 width=37) (actual time=3.217..3.217 rows=5,721 loops=1)

  • Buckets: 8,192 Batches: 1 Memory Usage: 463kB
13. 1.643 1.643 ↑ 1.0 5,721 1

Seq Scan on t_bases b (cost=0.00..100.77 rows=5,766 width=37) (actual time=0.017..1.643 rows=5,721 loops=1)

14. 0.079 0.252 ↑ 1.0 227 1

Hash (cost=9.23..9.23 rows=227 width=57) (actual time=0.252..0.252 rows=227 loops=1)

  • Buckets: 1,024 Batches: 1 Memory Usage: 28kB
15. 0.173 0.173 ↑ 1.0 227 1

Seq Scan on t_work_note_type wt (cost=0.00..9.23 rows=227 width=57) (actual time=0.015..0.173 rows=227 loops=1)

16. 1.558 2.749 ↑ 1.0 5,721 1

Hash (cost=100.77..100.77 rows=5,766 width=37) (actual time=2.749..2.749 rows=5,721 loops=1)

  • Buckets: 8,192 Batches: 1 Memory Usage: 463kB
17. 1.191 1.191 ↑ 1.0 5,721 1

Seq Scan on t_bases bt (cost=0.00..100.77 rows=5,766 width=37) (actual time=0.007..1.191 rows=5,721 loops=1)

18. 4.145 8.421 ↑ 1.0 13,628 1

Hash (cost=239.84..239.84 rows=13,842 width=65) (actual time=8.420..8.421 rows=13,628 loops=1)

  • Buckets: 16,384 Batches: 1 Memory Usage: 1,454kB
19. 4.276 4.276 ↑ 1.0 13,628 1

Seq Scan on t_subst_text st (cost=0.00..239.84 rows=13,842 width=65) (actual time=0.015..4.276 rows=13,628 loops=1)

20. 14.058 88.442 ↓ 1.0 30,044 1

Hash (cost=4,091.66..4,091.66 rows=30,041 width=154) (actual time=88.442..88.442 rows=30,044 loops=1)

  • Buckets: 32,768 Batches: 1 Memory Usage: 4,562kB
21. 41.354 74.384 ↓ 1.0 30,044 1

Hash Left Join (cost=883.76..4,091.66 rows=30,041 width=154) (actual time=23.440..74.384 rows=30,044 loops=1)

  • Hash Cond: (w_user.id_employee = e.id)
22. 9.690 9.690 ↓ 1.0 30,044 1

Seq Scan on t_workers w_user (cost=0.00..3,129.04 rows=30,041 width=105) (actual time=0.008..9.690 rows=30,044 loops=1)

23. 7.125 23.340 ↑ 1.0 24,411 1

Hash (cost=796.06..796.06 rows=25,057 width=57) (actual time=23.340..23.340 rows=24,411 loops=1)

  • Buckets: 32,768 Batches: 1 Memory Usage: 2,437kB
24. 16.215 16.215 ↑ 1.0 24,411 1

Seq Scan on t_employee e (cost=0.00..796.06 rows=25,057 width=57) (actual time=0.014..16.215 rows=24,411 loops=1)

25. 0.003 0.026 ↑ 2.0 1 1

Hash (cost=3.58..3.58 rows=2 width=8) (actual time=0.026..0.026 rows=1 loops=1)

  • Buckets: 1,024 Batches: 1 Memory Usage: 9kB
26. 0.023 0.023 ↑ 2.0 1 1

Index Scan using ix_t_work_note_answ_id_order on t_work_note_answ (cost=0.56..3.58 rows=2 width=8) (actual time=0.022..0.023 rows=1 loops=1)

  • Index Cond: (id_order = '311001246393613'::bigint)
27. 0.002 0.097 ↓ 0.0 0 1

Hash Left Join (cost=138.90..234.32 rows=21 width=81) (actual time=0.097..0.097 rows=0 loops=1)

  • Hash Cond: (b_1.id_time_zone = tz.id)
28. 0.009 0.095 ↓ 0.0 0 1

Nested Loop Left Join (cost=127.21..201.22 rows=21 width=53) (actual time=0.095..0.095 rows=0 loops=1)

29. 0.011 0.086 ↓ 0.0 0 1

Bitmap Heap Scan on t_remind rem (cost=126.93..150.85 rows=21 width=53) (actual time=0.086..0.086 rows=0 loops=1)

  • Recheck Cond: ((id_object @> ARRAY[wn.id]) AND (c_class_code = 'T_WORK_NOTE'::text) AND (c_view_code = 'V_WORK_NOTE'::text) AND (c_blocked = 0))
  • Filter: (id_worker IS NULL)
30. 0.011 0.075 ↓ 0.0 0 1

BitmapAnd (cost=126.93..126.93 rows=22 width=0) (actual time=0.075..0.075 rows=0 loops=1)

31. 0.064 0.064 ↓ 0.0 0 1

Bitmap Index Scan on idx_t_remind_id_object (cost=0.00..7.15 rows=701 width=0) (actual time=0.064..0.064 rows=0 loops=1)

  • Index Cond: (id_object @> ARRAY[wn.id])
32. 0.000 0.000 ↓ 0.0 0

Bitmap Index Scan on idx_t_remind_class_view (cost=0.00..118.50 rows=4,451 width=0) (never executed)

  • Index Cond: ((c_class_code = 'T_WORK_NOTE'::text) AND (c_view_code = 'V_WORK_NOTE'::text))
33. 0.000 0.000 ↓ 0.0 0

Index Scan using pk_t_bases on t_bases b_1 (cost=0.28..2.40 rows=1 width=8) (never executed)

  • Index Cond: (id = rem.id_base)
34. 0.000 0.000 ↓ 0.0 0

Hash (cost=9.60..9.60 rows=596 width=19) (never executed)

35. 0.000 0.000 ↓ 0.0 0

Seq Scan on t_time_zone tz (cost=0.00..9.60 rows=596 width=19) (never executed)

Planning time : 12.932 ms
Execution time : 87,129.338 ms