explain.depesz.com

PostgreSQL's explain analyze made readable

Result: HmKm

Settings

Optimization(s) for this plan:

# exclusive inclusive rows x rows loops node
1. 0.005 14.038 ↑ 1.0 1 1

Nested Loop Left Join (cost=278.96..370.01 rows=1 width=4,368) (actual time=14.031..14.038 rows=1 loops=1)

2. 0.003 10.995 ↑ 1.0 1 1

Nested Loop Left Join (cost=278.71..368.48 rows=1 width=4,336) (actual time=10.988..10.995 rows=1 loops=1)

3. 0.003 10.992 ↑ 1.0 1 1

Nested Loop Left Join (cost=278.30..360.04 rows=1 width=4,252) (actual time=10.986..10.992 rows=1 loops=1)

4. 0.002 10.989 ↑ 1.0 1 1

Nested Loop Left Join (cost=277.88..351.59 rows=1 width=4,196) (actual time=10.983..10.989 rows=1 loops=1)

5. 0.002 10.986 ↑ 1.0 1 1

Nested Loop Left Join (cost=277.45..343.14 rows=1 width=4,161) (actual time=10.980..10.986 rows=1 loops=1)

6. 0.005 10.984 ↑ 1.0 1 1

Nested Loop Left Join (cost=277.03..334.68 rows=1 width=4,137) (actual time=10.978..10.984 rows=1 loops=1)

7. 0.004 10.978 ↑ 1.0 1 1

Nested Loop Left Join (cost=276.61..326.23 rows=1 width=4,004) (actual time=10.973..10.978 rows=1 loops=1)

8. 0.004 10.961 ↑ 1.0 1 1

Nested Loop Left Join (cost=276.19..317.79 rows=1 width=3,873) (actual time=10.957..10.961 rows=1 loops=1)

9. 0.003 10.949 ↑ 1.0 1 1

Nested Loop Left Join (cost=275.78..309.35 rows=1 width=3,092) (actual time=10.946..10.949 rows=1 loops=1)

10. 0.004 10.945 ↑ 1.0 1 1

Nested Loop Left Join (cost=275.49..301.03 rows=1 width=3,061) (actual time=10.943..10.945 rows=1 loops=1)

11. 0.017 10.940 ↑ 1.0 1 1

Hash Right Join (cost=275.21..292.72 rows=1 width=2,983) (actual time=10.938..10.940 rows=1 loops=1)

  • Hash Cond: (((priv_ord_samples_note_translation.production_notes_id)::bpchar = (sc_items.production_notes_id)::bpchar) AND ((priv_ord_samples_note_translation.vendor_id)::bpchar = (sc_items.vendor_id)::bpchar))
12. 1.879 1.879 ↓ 0.0 0 1

Function Scan on priv_ord_samples_note_translation (cost=0.25..10.25 rows=1,000 width=160) (actual time=1.879..1.879 rows=0 loops=1)

13. 0.005 9.044 ↑ 1.0 1 1

Hash (cost=274.95..274.95 rows=1 width=2,887) (actual time=9.044..9.044 rows=1 loops=1)

  • Buckets: 1024 Batches: 1 Memory Usage: 1kB
14. 0.010 9.039 ↑ 1.0 1 1

Bitmap Heap Scan on sc_items (cost=270.93..274.95 rows=1 width=2,887) (actual time=9.038..9.039 rows=1 loops=1)

  • Recheck Cond: (((cart_id)::bpchar = 'CA18080004816086'::bpchar) AND ((item_order_status)::text = 'OK'::text))
15. 0.003 9.029 ↓ 0.0 0 1

BitmapAnd (cost=270.93..270.93 rows=1 width=0) (actual time=9.029..9.029 rows=0 loops=1)

16. 0.019 0.019 ↑ 369.0 1 1

Bitmap Index Scan on ix_sc_items_cart_id (cost=0.00..15.20 rows=369 width=0) (actual time=0.019..0.019 rows=1 loops=1)

  • Index Cond: ((cart_id)::bpchar = 'CA18080004816086'::bpchar)
17. 9.007 9.007 ↓ 4.5 44,821 1

Bitmap Index Scan on ix_sc_items_item_order_status (cost=0.00..255.48 rows=10,007 width=0) (actual time=9.007..9.007 rows=44,821 loops=1)

  • Index Cond: ((item_order_status)::text = 'OK'::text)
18. 0.001 0.001 ↓ 0.0 0 1

Index Scan using pk_inv_groups on inv_groups (cost=0.28..8.30 rows=1 width=95) (actual time=0.001..0.001 rows=0 loops=1)

  • Index Cond: ((sc_items.inv_group_id)::bpchar = (inv_group_id)::bpchar)
19. 0.001 0.001 ↓ 0.0 0 1

Index Scan using pk_inv_group_items on inv_group_items (cost=0.29..8.30 rows=1 width=65) (actual time=0.001..0.001 rows=0 loops=1)

  • Index Cond: (((sc_items.inv_group_id)::bpchar = (inv_group_id)::bpchar) AND ((sc_items.inv_item_id)::bpchar = (inv_item_id)::bpchar))
20. 0.008 0.008 ↑ 1.0 1 1

Index Scan using pk_tpl_templates on tpl_templates (cost=0.41..8.43 rows=1 width=798) (actual time=0.008..0.008 rows=1 loops=1)

  • Index Cond: ((sc_items.template_id)::bpchar = (template_id)::bpchar)
21. 0.013 0.013 ↑ 1.0 1 1

Index Scan using uk_tpl_assignments_template_assignment_cust_source on tpl_assignments (cost=0.41..8.43 rows=1 width=165) (actual time=0.013..0.013 rows=1 loops=1)

  • Index Cond: (((sc_items.template_id)::bpchar = (template_id)::bpchar) AND ((sc_items.assignment_id)::bpchar = (assignment_id)::bpchar))
22. 0.001 0.001 ↓ 0.0 0 1

Index Scan using uk_acct_contacts_contact_account_id on acct_contacts (cost=0.42..8.44 rows=1 width=150) (actual time=0.001..0.001 rows=0 loops=1)

  • Index Cond: ((contact_id)::bpchar = (sc_items.sub_vendor_contact_id)::bpchar)
23. 0.000 0.000 ↓ 0.0 0 1

Index Scan using pk_acct_phones on acct_phones (cost=0.42..8.44 rows=1 width=41) (actual time=0.000..0.000 rows=0 loops=1)

  • Index Cond: (((contact_id)::bpchar = (sc_items.sub_vendor_contact_id)::bpchar) AND ((phone_type)::text = 'Primary'::text))
24. 0.001 0.001 ↓ 0.0 0 1

Index Scan using ix_acct_e_info_contact_id on acct_e_info (cost=0.42..8.44 rows=1 width=52) (actual time=0.001..0.001 rows=0 loops=1)

  • Index Cond: ((contact_id)::bpchar = (sc_items.sub_vendor_contact_id)::bpchar)
  • Filter: ((e_info_type)::text = 'Primary'::text)
25. 0.000 0.000 ↓ 0.0 0 1

Index Scan using ix_acct_addresses_contact_id on acct_addresses (cost=0.42..8.44 rows=1 width=73) (actual time=0.000..0.000 rows=0 loops=1)

  • Index Cond: ((contact_id)::bpchar = (sc_items.sub_vendor_contact_id)::bpchar)
  • Filter: ((address_type)::text = 'Primary'::text)
26. 0.000 0.000 ↓ 0.0 0 1

Index Scan using pk_ct_provisions on ct_provisions (cost=0.41..8.43 rows=1 width=101) (actual time=0.000..0.000 rows=0 loops=1)

  • Index Cond: ((provision_id)::bpchar = (sc_items.provision_id)::bpchar)
27. 0.013 3.038 ↓ 0.0 0 1

Subquery Scan on xtc (cost=0.25..1.52 rows=1 width=96) (actual time=3.038..3.038 rows=0 loops=1)

  • Filter: (((xtc.cart_id)::bpchar = 'CA18080004816086'::bpchar) AND ((sc_items.cart_id)::bpchar = (xtc.cart_id)::bpchar) AND ((sc_items.cart_item_id)::bpchar = (xtc.cart_item_id)::bpchar))
28. 0.000 3.025 ↓ 0.0 0 1

Limit (cost=0.25..1.50 rows=1 width=96) (actual time=3.025..3.025 rows=0 loops=1)

29. 3.025 3.025 ↓ 0.0 0 1

Function Scan on priv_cart_item_tax_classifications tc (cost=0.25..1.50 rows=1 width=96) (actual time=3.025..3.025 rows=0 loops=1)

  • Filter: (detail_price_type = 'BASE PRICE'::text)