explain.depesz.com

A tool for finding a real cause for slow queries.

Result: A5i

options
Did it help? Consider supporting us - Bitcoin address: 12v2hUztAk2LgzQ9H9LMwuU32urHMjZQnq
# exclusive inclusive rows x rows loops node
1. 0.016 1051.797 ↓ 2.0 2 1

Nested Loop Left Join (cost=20714.34..21232.78 rows=1 width=2573) (actual time=927.414..1051.797 rows=2 loops=1)

2. 0.016 1051.771 ↓ 2.0 2 1

Nested Loop Left Join (cost=20714.34..21232.50 rows=1 width=2523) (actual time=927.400..1051.771 rows=2 loops=1)

3. 0.014 1051.737 ↓ 2.0 2 1

Nested Loop Left Join (cost=20714.34..21232.10 rows=1 width=2507) (actual time=927.383..1051.737 rows=2 loops=1)

4. 0.015 1051.699 ↓ 2.0 2 1

Nested Loop Left Join (cost=20714.34..21227.95 rows=1 width=1865) (actual time=927.361..1051.699 rows=2 loops=1)

5. 0.013 1051.668 ↓ 2.0 2 1

Nested Loop Left Join (cost=20714.34..21225.65 rows=1 width=1665) (actual time=927.346..1051.668 rows=2 loops=1)

6. 0.031 1051.645 ↓ 2.0 2 1

Nested Loop (cost=20714.34..21225.34 rows=1 width=1245) (actual time=927.334..1051.645 rows=2 loops=1)

7. 0.034 1051.560 ↓ 9.0 9 1

Nested Loop Left Join (cost=20714.34..21221.04 rows=1 width=1027) (actual time=927.315..1051.560 rows=9 loops=1)

8. 0.046 1051.517 ↓ 9.0 9 1

Nested Loop (cost=20714.34..21216.76 rows=1 width=987) (actual time=927.306..1051.517 rows=9 loops=1)

9. 0.052 1051.444 ↓ 9.0 9 1

Nested Loop Left Join (cost=20714.34..21215.65 rows=1 width=942) (actual time=927.295..1051.444 rows=9 loops=1)

  • Join Filter: (aps.id_application_status = a3.id_application_status)
10. 0.155 1051.347 ↓ 9.0 9 1

Nested Loop Left Join (cost=20714.34..21214.43 rows=1 width=910) (actual time=927.272..1051.347 rows=9 loops=1)

11. 132.993 1051.138 ↓ 9.0 9 1

Hash Join (cost=20714.34..21210.15 rows=1 width=821) (actual time=927.249..1051.138 rows=9 loops=1)

  • Hash Cond: (a2.id_application = a3.id_application)
12. 510.944 913.247 ↓ 8.3 142564 1

HashAggregate (cost=20700.78..20959.46 rows=17245 width=24) (actual time=733.890..913.247 rows=142564 loops=1)

13. 402.303 402.303 ↓ 3.3 185885 1

Index Scan using idx_application_date_version_to_null on bo_application (cost=0.00..20272.22 rows=57141 width=24) (actual time=0.024..402.303 rows=185885 loops=1)

  • Filter: ((NOT is_test) AND (date_application_sent IS NOT NULL) AND (id_application_status = ANY ('{3,8,10,11,12,13,14,15,16,17}'::bigint[])))
14. 0.107 4.898 ↓ 14.0 14 1

Hash (cost=13.55..13.55 rows=1 width=805) (actual time=4.898..4.898 rows=14 loops=1)

15. 0.382 4.791 ↓ 14.0 14 1

Nested Loop (cost=0.00..13.55 rows=1 width=805) (actual time=0.071..4.791 rows=14 loops=1)

16. 0.910 3.905 ↓ 126.0 126 1

Nested Loop Left Join (cost=0.00..13.26 rows=1 width=675) (actual time=0.054..3.905 rows=126 loops=1)

17. 0.870 2.491 ↓ 126.0 126 1

Nested Loop (cost=0.00..12.97 rows=1 width=599) (actual time=0.044..2.491 rows=126 loops=1)

18. 0.865 0.865 ↓ 126.0 126 1

Index Scan using hdl_test_it on bo_application a3 (cost=0.00..8.69 rows=1 width=490) (actual time=0.027..0.865 rows=126 loops=1)

  • Index Cond: ((date_application_sent >= '2012-04-01 00:00:00'::timestamp without time zone) AND (date_application_sent < '2012-04-08 23:59:00'::timestamp without time zone))
  • Filter: ((id_application_status = ANY ('{3,8,10,11,12,13,14,15,16,17}'::bigint[])) AND (id_application_status = 17))
19. 0.756 0.756 ↑ 1.0 1 126

Index Scan using idx_product_id on bo_product p (cost=0.00..4.27 rows=1 width=109) (actual time=0.004..0.006 rows=1 loops=126)

  • Index Cond: (p.id_product = a3.id_product)
20. 0.504 0.504 ↑ 1.0 1 126

Index Scan using idx_institution_id on bo_institution i (cost=0.00..0.27 rows=1 width=76) (actual time=0.003..0.004 rows=1 loops=126)

  • Index Cond: (i.id_institution = p.id_institution)
21. 0.504 0.504 ↓ 0.0 0 126

Index Scan using idx_product_type_id on bo_product_type pt (cost=0.00..0.28 rows=1 width=130) (actual time=0.004..0.004 rows=0 loops=126)

  • Index Cond: (pt.id_product_type = p.id_product_type)
  • Filter: (4 = id_product_type_group)
22. 0.054 0.054 ↑ 1.0 1 9

Index Scan using idx_branch_id on bo_branch b (cost=0.00..4.27 rows=1 width=89) (actual time=0.005..0.006 rows=1 loops=9)

  • Index Cond: (b.id_branch = a3.id_branch)
23. 0.045 0.045 ↑ 1.0 1 9

Seq Scan on bo_application_status aps (cost=0.00..1.21 rows=1 width=32) (actual time=0.004..0.005 rows=1 loops=9)

  • Filter: (id_application_status = 17)
24. 0.027 0.027 ↑ 1.0 1 9

Seq Scan on bo_product_type_group pc (cost=0.00..1.10 rows=1 width=45) (actual time=0.002..0.003 rows=1 loops=9)

  • Filter: (id_product_type_group = 4)
25. 0.009 0.009 ↓ 0.0 0 9

Index Scan using bo_dictionary_form_value_pkey on bo_dictionary_form_value bdfv (cost=0.00..4.27 rows=1 width=40) (actual time=0.001..0.001 rows=0 loops=9)

  • Index Cond: (a3.id_recommended_client = bdfv.id_dictionary_form_value)
26. 0.054 0.054 ↓ 0.0 0 9

Index Scan using idx_case_id on bo_case c (cost=0.00..4.28 rows=1 width=218) (actual time=0.006..0.006 rows=0 loops=9)

  • Index Cond: (c.id_case = a3.id_case)
  • Filter: (id_unit = 77)
27. 0.010 0.010 ↑ 1.0 1 2

Index Scan using idx_unit_id on bo_unit u (cost=0.00..0.30 rows=1 width=420) (actual time=0.004..0.005 rows=1 loops=2)

  • Index Cond: ((u.id_unit = 77) AND (u.id_unit = c.id_unit))
28. 0.016 0.016 ↑ 1.0 1 2

Index Scan using idx_employee_id on bo_employee emp (cost=0.00..2.29 rows=1 width=200) (actual time=0.007..0.008 rows=1 loops=2)

  • Index Cond: (emp.id_employee = c.id_employee)
29. 0.024 0.024 ↑ 1.0 1 2

Index Scan using idx_client_id on bo_client cl (cost=0.00..4.13 rows=1 width=642) (actual time=0.011..0.012 rows=1 loops=2)

  • Index Cond: (cl.id_client = c.id_client)
30. 0.018 0.018 ↑ 1.0 1 2

Index Scan using pk_bo_client_corporation on bo_client_corporation bcc (cost=0.00..0.39 rows=1 width=16) (actual time=0.008..0.009 rows=1 loops=2)

  • Index Cond: (bcc.id_client = cl.id_client)
31. 0.010 0.010 ↑ 1.0 1 2

Index Scan using pk_bo_dictionary2_value on bo_dictionary2_value bd2v (cost=0.00..0.27 rows=1 width=50) (actual time=0.005..0.005 rows=1 loops=2)

  • Index Cond: (bcc.id_dictionary_value = bd2v.id_dictionary_value)