explain.depesz.com

PostgreSQL's explain analyze made readable

Result: j3qa

Settings
# exclusive inclusive rows x rows loops node
1. 0.158 0.628 ↓ 94.0 94 1

Nested Loop Left Join (cost=5.28..103.82 rows=1 width=4) (actual time=0.112..0.628 rows=94 loops=1)

2. 0.074 0.376 ↓ 94.0 94 1

Nested Loop Left Join (cost=4.85..92.91 rows=1 width=4) (actual time=0.103..0.376 rows=94 loops=1)

3. 0.012 0.222 ↓ 8.0 8 1

Nested Loop Left Join (cost=4.28..81.73 rows=1 width=4) (actual time=0.091..0.222 rows=8 loops=1)

4. 0.020 0.170 ↓ 8.0 8 1

Nested Loop Left Join (cost=3.84..70.82 rows=1 width=4) (actual time=0.082..0.170 rows=8 loops=1)

5. 0.009 0.134 ↓ 8.0 8 1

Nested Loop Left Join (cost=3.41..59.92 rows=1 width=4) (actual time=0.071..0.134 rows=8 loops=1)

6. 0.011 0.109 ↓ 2.0 2 1

Nested Loop Left Join (cost=2.85..48.75 rows=1 width=4) (actual time=0.060..0.109 rows=2 loops=1)

7. 0.005 0.088 ↓ 2.0 2 1

Nested Loop Left Join (cost=2.42..35.86 rows=1 width=4) (actual time=0.050..0.088 rows=2 loops=1)

8. 0.007 0.073 ↓ 2.0 2 1

Nested Loop (cost=1.99..27.40 rows=1 width=4) (actual time=0.042..0.073 rows=2 loops=1)

  • Join Filter: (orders.id = order_addresses.order_id)
9. 0.010 0.054 ↓ 2.0 2 1

Nested Loop (cost=1.56..26.91 rows=1 width=16) (actual time=0.031..0.054 rows=2 loops=1)

  • Join Filter: (orders.id = calculated_information.order_id)
10. 0.003 0.034 ↓ 2.0 2 1

Nested Loop (cost=0.99..26.08 rows=1 width=12) (actual time=0.020..0.034 rows=2 loops=1)

11. 0.017 0.017 ↑ 1.0 2 1

Index Only Scan using orders_pkey on orders (cost=0.56..13.16 rows=2 width=4) (actual time=0.009..0.017 rows=2 loops=1)

  • Index Cond: (id = ANY ('{26236857,27923671}'::integer[]))
  • Heap Fetches: 1
12. 0.014 0.014 ↑ 1.0 1 2

Index Only Scan using order_application_users_order_id_application_user_id_unique on order_application_users (cost=0.43..6.45 rows=1 width=8) (actual time=0.006..0.007 rows=1 loops=2)

  • Index Cond: (order_id = orders.id)
  • Heap Fetches: 1
13. 0.010 0.010 ↑ 1.0 1 2

Index Only Scan using orders_pkey on orders calculated_information (cost=0.56..0.82 rows=1 width=4) (actual time=0.005..0.005 rows=1 loops=2)

  • Index Cond: (order_id = order_application_users.order_id)
  • Heap Fetches: 0
14. 0.012 0.012 ↑ 1.0 1 2

Index Scan using order_addresses_order_id_index on order_addresses (cost=0.43..0.48 rows=1 width=8) (actual time=0.006..0.006 rows=1 loops=2)

  • Index Cond: (order_id = calculated_information.order_id)
  • Filter: (is_current IS TRUE)
15. 0.010 0.010 ↑ 1.0 1 2

Index Scan using order_storekeepers_order_id_index on order_storekeepers storekeeper (cost=0.43..8.45 rows=1 width=8) (actual time=0.005..0.005 rows=1 loops=2)

  • Index Cond: (order_id = orders.id)
  • Filter: (is_current IS TRUE)
16. 0.010 0.010 ↓ 0.0 0 2

Index Scan using order_personal_shoppers_order_id_index on order_personal_shoppers personal_shopper (cost=0.42..12.88 rows=1 width=8) (actual time=0.005..0.005 rows=0 loops=2)

  • Index Cond: ((order_id = orders.id) AND (order_id = ANY ('{26236857,27923671}'::bigint[])))
  • Filter: (is_current IS TRUE)
17. 0.016 0.016 ↓ 4.0 4 2

Index Only Scan using order_product_order_id_store_id_product_id_index on order_product (cost=0.56..11.16 rows=1 width=4) (actual time=0.006..0.008 rows=4 loops=2)

  • Index Cond: ((order_id = orders.id) AND (order_id = ANY ('{26236857,27923671}'::integer[])))
  • Heap Fetches: 10
18. 0.016 0.016 ↓ 0.0 0 8

Index Only Scan using order_whims_order_id_index on order_whims (cost=0.43..10.89 rows=1 width=4) (actual time=0.002..0.002 rows=0 loops=8)

  • Index Cond: ((order_id = orders.id) AND (order_id = ANY ('{26236857,27923671}'::integer[])))
  • Heap Fetches: 0
19. 0.040 0.040 ↑ 1.0 1 8

Index Only Scan using order_stores_order_id_index on order_stores (cost=0.43..10.89 rows=1 width=4) (actual time=0.003..0.005 rows=1 loops=8)

  • Index Cond: ((order_id = orders.id) AND (order_id = ANY ('{26236857,27923671}'::integer[])))
  • Heap Fetches: 5
20. 0.080 0.080 ↓ 12.0 12 8

Index Only Scan using order_modifications_order_id_index on order_modifications (cost=0.57..11.17 rows=1 width=4) (actual time=0.004..0.010 rows=12 loops=8)

  • Index Cond: ((order_id = orders.id) AND (order_id = ANY ('{26236857,27923671}'::integer[])))
  • Heap Fetches: 70
21. 0.094 0.094 ↓ 0.0 0 94

Index Only Scan using order_discounts_order_id_index on order_discounts (cost=0.43..10.90 rows=1 width=4) (actual time=0.001..0.001 rows=0 loops=94)

  • Index Cond: ((order_id = orders.id) AND (order_id = ANY ('{26236857,27923671}'::integer[])))
  • Heap Fetches: 0