explain.depesz.com

PostgreSQL's explain analyze made readable

Result: bNQQ

Settings
# exclusive inclusive rows x rows loops node
1. 0.003 18,671.445 ↓ 0.0 0 1

Limit (cost=112,393.93..112,393.93 rows=1 width=2,157) (actual time=18,671.445..18,671.445 rows=0 loops=1)

2. 0.167 18,671.442 ↓ 0.0 0 1

Sort (cost=112,393.93..112,393.93 rows=1 width=2,157) (actual time=18,671.442..18,671.442 rows=0 loops=1)

  • Sort Key: selectprod0_.changestamp DESC
  • Sort Method: quicksort Memory: 25kB
3. 1.786 18,671.275 ↓ 0.0 0 1

Nested Loop (cost=52,638.57..112,393.92 rows=1 width=2,157) (actual time=18,671.275..18,671.275 rows=0 loops=1)

  • Join Filter: ((selectprod0_.id = checkscans1_.select_product_id) AND (((selectprod0_.doc_status)::text = 'for_end_scans'::text) OR (((selectprod0_.doc_status)::text = 'end'::text) AND ((checkscans1_.check_scans_status)::text = 'BAD'::text))))
  • Rows Removed by Join Filter: 2101
4. 0.266 18,667.872 ↓ 11.0 11 1

Nested Loop (cost=52,638.57..112,385.91 rows=1 width=2,199) (actual time=7,466.996..18,667.872 rows=11 loops=1)

  • Join Filter: (selectprod0_.id = selectprod0_9_.owner_id)
5. 0.130 18,666.869 ↓ 11.0 11 1

Nested Loop Left Join (cost=52,638.14..112,385.41 rows=1 width=2,101) (actual time=7,466.948..18,666.869 rows=11 loops=1)

6. 0.140 18,666.288 ↓ 11.0 11 1

Nested Loop Left Join (cost=52,637.71..112,378.09 rows=1 width=2,077) (actual time=7,466.893..18,666.288 rows=11 loops=1)

7. 0.154 18,665.763 ↓ 11.0 11 1

Nested Loop (cost=52,637.28..112,370.70 rows=1 width=2,051) (actual time=7,466.831..18,665.763 rows=11 loops=1)

  • Join Filter: (selectprod0_.id = selectprod0_6_.owner_id)
8. 0.171 18,665.312 ↓ 11.0 11 1

Nested Loop (cost=52,636.85..112,370.20 rows=1 width=1,941) (actual time=7,466.796..18,665.312 rows=11 loops=1)

  • Join Filter: (selectprod0_.id = selectprod0_5_.owner_id)
9. 0.182 18,664.668 ↓ 11.0 11 1

Nested Loop (cost=52,636.42..112,369.67 rows=1 width=1,102) (actual time=7,466.757..18,664.668 rows=11 loops=1)

  • Join Filter: (selectprod0_.id = selectprod0_1_.owner_id)
10. 0.150 18,664.167 ↓ 11.0 11 1

Nested Loop (cost=52,635.99..112,369.14 rows=1 width=654) (actual time=7,466.708..18,664.167 rows=11 loops=1)

  • Join Filter: (selectprod0_.id = selectprod0_2_.owner_id)
11. 240.981 18,662.598 ↓ 11.0 11 1

Nested Loop (cost=52,635.56..112,368.41 rows=1 width=605) (actual time=7,466.664..18,662.598 rows=11 loops=1)

  • Join Filter: (selectprod0_.id = selectprod0_4_.owner_id)
12. 438.065 16,941.579 ↓ 451.8 105,717 1

Nested Loop (cost=52,635.13..112,232.19 rows=234 width=140) (actual time=3,938.113..16,941.579 rows=105,717 loops=1)

13. 11,059.341 14,917.759 ↓ 19.8 105,717 1

Bitmap Heap Scan on ups_doc selectprod0_ (cost=52,634.70..73,107.65 rows=5,352 width=81) (actual time=3,938.060..14,917.759 rows=105,717 loops=1)

  • Recheck Cond: (((((doc_module)::text = 'mc'::text) AND ((doc_type)::text = 'select_product'::text) AND ((doc_status)::text = 'for_end_scans'::text)) OR (((doc_module)::text = 'mc'::text) AND ((doc_type)::text = 'select_product'::text) AND ((doc_status)::text = 'end'::text))) AND (createstamp >= '2019-08-11 13:49:28.945'::timestamp without time zone))
  • Rows Removed by Index Recheck: 8758319
  • Filter: ((isarchive = '0'::numeric) AND (istemplate = '0'::numeric))
  • Heap Blocks: exact=36784 lossy=150715
14. 525.654 3,858.418 ↓ 0.0 0 1

BitmapAnd (cost=52,634.70..52,634.70 rows=5,359 width=0) (actual time=3,858.418..3,858.418 rows=0 loops=1)

15. 0.003 2,065.633 ↓ 0.0 0 1

BitmapOr (cost=7,889.12..7,889.12 rows=202,025 width=0) (actual time=2,065.633..2,065.633 rows=0 loops=1)

16. 0.109 0.109 ↑ 128.6 16 1

Bitmap Index Scan on idx_ups_doc_test1 (cost=0.00..82.28 rows=2,057 width=0) (actual time=0.109..0.109 rows=16 loops=1)

  • Index Cond: (((doc_module)::text = 'mc'::text) AND ((doc_type)::text = 'select_product'::text) AND ((doc_status)::text = 'for_end_scans'::text))
17. 2,065.521 2,065.521 ↓ 8.7 1,741,260 1

Bitmap Index Scan on idx_ups_doc_test1 (cost=0.00..7,804.16 rows=199,968 width=0) (actual time=2,065.521..2,065.521 rows=1,741,260 loops=1)

  • Index Cond: (((doc_module)::text = 'mc'::text) AND ((doc_type)::text = 'select_product'::text) AND ((doc_status)::text = 'end'::text))
18. 1,267.131 1,267.131 ↓ 2.3 4,063,972 1

Bitmap Index Scan on idx_ups_doc_createstamp (cost=0.00..44,743.99 rows=1,748,190 width=0) (actual time=1,267.131..1,267.131 rows=4,063,972 loops=1)

  • Index Cond: (createstamp >= '2019-08-11 13:49:28.945'::timestamp without time zone)
19. 1,585.755 1,585.755 ↑ 1.0 1 105,717

Index Scan using pk_mc_doc_cl_ownership on mc_doc_cl_ownership selectprod0_3_ (cost=0.43..7.30 rows=1 width=59) (actual time=0.014..0.015 rows=1 loops=105,717)

  • Index Cond: (owner_id = selectprod0_.id)
20. 1,480.038 1,480.038 ↓ 0.0 0 105,717

Index Scan using pk_mc_doc_product on mc_doc_product selectprod0_4_ (cost=0.43..0.57 rows=1 width=465) (actual time=0.014..0.014 rows=0 loops=105,717)

  • Index Cond: (owner_id = selectprod0_3_.owner_id)
  • Filter: ((client_id = '15901355'::numeric) AND (point_id = '15421835'::numeric))
  • Rows Removed by Filter: 1
21. 1.419 1.419 ↑ 1.0 1 11

Index Scan using pk_mc_dic on mc_dic selectprod0_2_ (cost=0.43..0.72 rows=1 width=49) (actual time=0.128..0.129 rows=1 loops=11)

  • Index Cond: (owner_id = selectprod0_3_.owner_id)
22. 0.319 0.319 ↑ 1.0 1 11

Index Scan using pk_mc_usr_fl_client on mc_usr_fl_client selectprod0_1_ (cost=0.43..0.51 rows=1 width=448) (actual time=0.028..0.029 rows=1 loops=11)

  • Index Cond: (owner_id = selectprod0_2_.owner_id)
23. 0.473 0.473 ↑ 1.0 1 11

Index Scan using pk_mc_doc_product_prm on mc_doc_product_prm selectprod0_5_ (cost=0.43..0.52 rows=1 width=839) (actual time=0.042..0.043 rows=1 loops=11)

  • Index Cond: (owner_id = selectprod0_2_.owner_id)
24. 0.297 0.297 ↑ 1.0 1 11

Index Scan using pk_mc_doc_employment on mc_doc_employment selectprod0_6_ (cost=0.43..0.48 rows=1 width=110) (actual time=0.026..0.027 rows=1 loops=11)

  • Index Cond: (owner_id = selectprod0_2_.owner_id)
25. 0.385 0.385 ↑ 1.0 1 11

Index Scan using pk_mc_doc_debts on mc_doc_debts selectprod0_7_ (cost=0.43..7.39 rows=1 width=32) (actual time=0.034..0.035 rows=1 loops=11)

  • Index Cond: (selectprod0_.id = owner_id)
26. 0.451 0.451 ↑ 1.0 1 11

Index Scan using pk_visual_appraisal on mc_visual_appraisal selectprod0_8_ (cost=0.43..7.30 rows=1 width=30) (actual time=0.040..0.041 rows=1 loops=11)

  • Index Cond: (selectprod0_.id = owner_id)
27. 0.737 0.737 ↑ 1.0 1 11

Index Scan using pk_mc_usr_fl_find on mc_usr_fl_find selectprod0_9_ (cost=0.43..0.49 rows=1 width=98) (actual time=0.065..0.067 rows=1 loops=11)

  • Index Cond: (owner_id = selectprod0_2_.owner_id)
28. 1.617 1.617 ↓ 1.1 191 11

Seq Scan on mc_credit_check_scans_info checkscans1_ (cost=0.00..4.67 rows=167 width=17) (actual time=0.013..0.147 rows=191 loops=11)

Planning time : 72.105 ms
Execution time : 18,682.568 ms