explain.depesz.com

PostgreSQL's explain analyze made readable

Result: BF8 : Test 1

Settings
# exclusive inclusive rows x rows loops node
1. 0.000 0.000 ↓ 0.0

Aggregate (cost=3,298,646.30..3,298,646.31 rows=1 width=32) (actual rows= loops=)

  • Functions: 350
  • Options: Inlining true, Optimization true, Expressions true, Deforming true
2. 0.000 0.000 ↓ 0.0

Limit (cost=3,298,646.15..3,298,646.17 rows=10 width=40) (actual rows= loops=)

3. 0.000 0.000 ↓ 0.0

Sort (cost=3,298,646.15..3,298,666.87 rows=8,291 width=40) (actual rows= loops=)

  • Sort Key: products.updated_at DESC NULLS LAST
4. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=399.45..3,298,466.98 rows=8,291 width=40) (actual rows= loops=)

  • -> Result (cost=0.00..0.01 rows=1 width=32)JIT:
5. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=390.88..3,227,048.83 rows=8,291 width=219) (actual rows= loops=)

6. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=299.47..2,468,942.93 rows=8,291 width=187) (actual rows= loops=)

7. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=294.55..2,427,949.22 rows=8,291 width=155) (actual rows= loops=)

8. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=17.26..128,626.91 rows=8,291 width=123) (actual rows= loops=)

9. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=9.93..67,605.56 rows=8,291 width=91) (actual rows= loops=)

10. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=9.78..66,151.88 rows=8,291 width=63) (actual rows= loops=)

  • Join Filter: (eav_text_description_1.product_id = products.id)
11. 0.000 0.000 ↓ 0.0

Merge Left Join (cost=4.67..53,273.23 rows=8,291 width=63) (actual rows= loops=)

  • Merge Cond: (products.id = eav_integer_pack_size_1.product_id)
12. 0.000 0.000 ↓ 0.0

Merge Left Join (cost=4.23..52,466.16 rows=8,291 width=63) (actual rows= loops=)

  • Merge Cond: (products.id = eav_string_sku_1.product_id)
13. 0.000 0.000 ↓ 0.0

Merge Left Join (cost=3.67..44,151.19 rows=8,291 width=50) (actual rows= loops=)

  • Merge Cond: (products.id = eav_string_alternative_id_1.product_id)
14. 0.000 0.000 ↓ 0.0

Merge Left Join (cost=3.10..35,836.23 rows=8,291 width=50) (actual rows= loops=)

  • Merge Cond: (products.id = eav_string_status.product_id)
15. 0.000 0.000 ↓ 0.0

Merge Left Join (cost=2.54..27,520.76 rows=8,291 width=37) (actual rows= loops=)

  • Merge Cond: (products.id = eav_string_short_description_1.product_id)
16. 0.000 0.000 ↓ 0.0

Merge Left Join (cost=1.98..19,205.29 rows=8,291 width=37) (actual rows= loops=)

  • Merge Cond: (products.id = eav_string.product_id)
17. 0.000 0.000 ↓ 0.0

Merge Left Join (cost=1.41..10,889.82 rows=8,291 width=24) (actual rows= loops=)

  • Merge Cond: (products.id = eav_float_cost_price_1.product_id)
18. 0.000 0.000 ↓ 0.0

Merge Left Join (cost=0.85..5,583.66 rows=8,291 width=20) (actual rows= loops=)

  • Merge Cond: (products.id = eav_float_unit_price_1.product_id)
19. 0.000 0.000 ↓ 0.0

Index Scan using products_pkey on products (cost=0.29..277.49 rows=8,291 width=16) (actual rows= loops=)

20. 0.000 0.000 ↓ 0.0

Materialize (cost=0.56..5,275.36 rows=806 width=8) (actual rows= loops=)

21. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.56..5,273.35 rows=806 width=8) (actual rows= loops=)

  • Join Filter: (attributes_2.id = eav_float_unit_price_1.attribute_id)
22. 0.000 0.000 ↓ 0.0

Index Scan using product_attribute_float_values_product_id_index on product_attribute_float_values eav_float_unit_price_1 (cost=0.42..3,430.05 rows=122,546 width=12) (actual rows= loops=)

23. 0.000 0.000 ↓ 0.0

Materialize (cost=0.14..5.11 rows=1 width=4) (actual rows= loops=)

24. 0.000 0.000 ↓ 0.0

Index Scan using attributes_attribute_set_id_code_company_id_unique on attributes attributes_2 (cost=0.14..5.10 rows=1 width=4) (actual rows= loops=)

  • Index Cond: ((code)::text = 'unit_sell_price'::text)
  • Filter: ((scope)::text = 'product'::text)
25. 0.000 0.000 ↓ 0.0

Materialize (cost=0.56..5,275.36 rows=806 width=8) (actual rows= loops=)

26. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.56..5,273.35 rows=806 width=8) (actual rows= loops=)

  • Join Filter: (attributes_1.id = eav_float_cost_price_1.attribute_id)
27. 0.000 0.000 ↓ 0.0

Index Scan using product_attribute_float_values_product_id_index on product_attribute_float_values eav_float_cost_price_1 (cost=0.42..3,430.05 rows=122,546 width=12) (actual rows= loops=)

28. 0.000 0.000 ↓ 0.0

Materialize (cost=0.14..5.11 rows=1 width=4) (actual rows= loops=)

29. 0.000 0.000 ↓ 0.0

Index Scan using attributes_attribute_set_id_code_company_id_unique on attributes attributes_1 (cost=0.14..5.10 rows=1 width=4) (actual rows= loops=)

  • Index Cond: ((code)::text = 'unit_cost_price'::text)
  • Filter: ((scope)::text = 'product'::text)
30. 0.000 0.000 ↓ 0.0

Materialize (cost=0.56..8,279.49 rows=1,220 width=17) (actual rows= loops=)

31. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.56..8,276.44 rows=1,220 width=17) (actual rows= loops=)

  • Join Filter: (attributes.id = eav_string.attribute_id)
32. 0.000 0.000 ↓ 0.0

Index Scan using product_attribute_string_values_product_id_index on product_attribute_string_values eav_string (cost=0.42..5,489.65 rows=185,446 width=21) (actual rows= loops=)

33. 0.000 0.000 ↓ 0.0

Materialize (cost=0.14..5.11 rows=1 width=4) (actual rows= loops=)

34. 0.000 0.000 ↓ 0.0

Index Scan using attributes_attribute_set_id_code_company_id_unique on attributes (cost=0.14..5.10 rows=1 width=4) (actual rows= loops=)

  • Index Cond: ((code)::text = 'name'::text)
  • Filter: ((scope)::text = 'product'::text)
35. 0.000 0.000 ↓ 0.0

Materialize (cost=0.56..8,279.49 rows=1,220 width=4) (actual rows= loops=)

36. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.56..8,276.44 rows=1,220 width=4) (actual rows= loops=)

  • Join Filter: (attributes_6.id = eav_string_short_description_1.attribute_id)
37. 0.000 0.000 ↓ 0.0

Index Scan using product_attribute_string_values_product_id_index on product_attribute_string_values eav_string_short_description_1 (cost=0.42..5,489.65 rows=185,446 width=8) (actual rows= loops=)

38. 0.000 0.000 ↓ 0.0

Materialize (cost=0.14..5.11 rows=1 width=4) (actual rows= loops=)

39. 0.000 0.000 ↓ 0.0

Index Scan using attributes_attribute_set_id_code_company_id_unique on attributes attributes_6 (cost=0.14..5.10 rows=1 width=4) (actual rows= loops=)

  • Index Cond: ((code)::text = 'short_description'::text)
  • Filter: ((scope)::text = 'product'::text)
40. 0.000 0.000 ↓ 0.0

Materialize (cost=0.56..8,279.49 rows=1,220 width=17) (actual rows= loops=)

41. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.56..8,276.44 rows=1,220 width=17) (actual rows= loops=)

  • Join Filter: (attributes_5.id = eav_string_status.attribute_id)
42. 0.000 0.000 ↓ 0.0

Index Scan using product_attribute_string_values_product_id_index on product_attribute_string_values eav_string_status (cost=0.42..5,489.65 rows=185,446 width=21) (actual rows= loops=)

43. 0.000 0.000 ↓ 0.0

Materialize (cost=0.14..5.11 rows=1 width=4) (actual rows= loops=)

44. 0.000 0.000 ↓ 0.0

Index Scan using attributes_attribute_set_id_code_company_id_unique on attributes attributes_5 (cost=0.14..5.10 rows=1 width=4) (actual rows= loops=)

  • Index Cond: ((code)::text = 'status'::text)
  • Filter: ((scope)::text = 'product'::text)
45. 0.000 0.000 ↓ 0.0

Materialize (cost=0.56..8,278.99 rows=1,220 width=4) (actual rows= loops=)

46. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.56..8,275.94 rows=1,220 width=4) (actual rows= loops=)

  • Join Filter: (attributes_4.id = eav_string_alternative_id_1.attribute_id)
47. 0.000 0.000 ↓ 0.0

Index Scan using product_attribute_string_values_product_id_index on product_attribute_string_values eav_string_alternative_id_1 (cost=0.42..5,489.65 rows=185,446 width=8) (actual rows= loops=)

48. 0.000 0.000 ↓ 0.0

Materialize (cost=0.14..4.60 rows=1 width=4) (actual rows= loops=)

49. 0.000 0.000 ↓ 0.0

Index Scan using attributes_attribute_set_id_code_company_id_unique on attributes attributes_4 (cost=0.14..4.60 rows=1 width=4) (actual rows= loops=)

  • Index Cond: ((code)::text = 'alternative_id'::text)
  • Filter: ((scope)::text = 'product'::text)
50. 0.000 0.000 ↓ 0.0

Materialize (cost=0.56..8,278.99 rows=1,220 width=17) (actual rows= loops=)

51. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.56..8,275.94 rows=1,220 width=17) (actual rows= loops=)

  • Join Filter: (attributes_3.id = eav_string_sku_1.attribute_id)
52. 0.000 0.000 ↓ 0.0

Index Scan using product_attribute_string_values_product_id_index on product_attribute_string_values eav_string_sku_1 (cost=0.42..5,489.65 rows=185,446 width=21) (actual rows= loops=)

53. 0.000 0.000 ↓ 0.0

Materialize (cost=0.14..4.60 rows=1 width=4) (actual rows= loops=)

54. 0.000 0.000 ↓ 0.0

Index Scan using attributes_attribute_set_id_code_company_id_unique on attributes attributes_3 (cost=0.14..4.60 rows=1 width=4) (actual rows= loops=)

  • Index Cond: ((code)::text = 'sku'::text)
  • Filter: ((scope)::text = 'product'::text)
55. 0.000 0.000 ↓ 0.0

Materialize (cost=0.43..784.90 rows=116 width=4) (actual rows= loops=)

56. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.43..784.61 rows=116 width=4) (actual rows= loops=)

  • Join Filter: (attributes_8.id = eav_integer_pack_size_1.attribute_id)
57. 0.000 0.000 ↓ 0.0

Index Scan using product_attribute_integer_values_product_id_index on product_attribute_integer_values eav_integer_pack_size_1 (cost=0.29..516.62 rows=17,559 width=8) (actual rows= loops=)

58. 0.000 0.000 ↓ 0.0

Materialize (cost=0.14..4.60 rows=1 width=4) (actual rows= loops=)

59. 0.000 0.000 ↓ 0.0

Index Scan using attributes_attribute_set_id_code_company_id_unique on attributes attributes_8 (cost=0.14..4.60 rows=1 width=4) (actual rows= loops=)

  • Index Cond: ((code)::text = 'pack_size'::text)
  • Filter: ((scope)::text = 'product'::text)
60. 0.000 0.000 ↓ 0.0

Materialize (cost=5.11..1,561.67 rows=91 width=4) (actual rows= loops=)

61. 0.000 0.000 ↓ 0.0

Hash Join (cost=5.11..1,561.21 rows=91 width=4) (actual rows= loops=)

  • Hash Cond: (eav_text_description_1.attribute_id = attributes_7.id)
62. 0.000 0.000 ↓ 0.0

Seq Scan on product_attribute_text_values eav_text_description_1 (cost=0.00..1,518.68 rows=13,868 width=8) (actual rows= loops=)

63. 0.000 0.000 ↓ 0.0

Hash (cost=5.10..5.10 rows=1 width=4) (actual rows= loops=)

64. 0.000 0.000 ↓ 0.0

Index Scan using attributes_attribute_set_id_code_company_id_unique on attributes attributes_7 (cost=0.14..5.10 rows=1 width=4) (actual rows= loops=)

  • Index Cond: ((code)::text = 'description'::text)
  • Filter: ((scope)::text = 'product'::text)
65. 0.000 0.000 ↓ 0.0

Index Scan using brands_pkey on brands (cost=0.14..0.18 rows=1 width=36) (actual rows= loops=)

  • Index Cond: (id = products.brand_id)
66.          

SubPlan (for Index Scan)

67. 0.000 0.000 ↓ 0.0

Result (cost=0.00..0.01 rows=1 width=32) (actual rows= loops=)

68. 0.000 0.000 ↓ 0.0

Aggregate (cost=7.33..7.34 rows=1 width=32) (actual rows= loops=)

69. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=0.29..7.31 rows=1 width=32) (actual rows= loops=)

70. 0.000 0.000 ↓ 0.0

Index Only Scan using labelables_label_id_type_labelable_id_unique on labelables (cost=0.14..4.86 rows=1 width=4) (actual rows= loops=)

  • Index Cond: ((type = 'products'::text) AND (labelable_id = products.id))
71. 0.000 0.000 ↓ 0.0

Index Scan using labels_pkey on labels (cost=0.14..2.37 rows=1 width=36) (actual rows= loops=)

  • Index Cond: (id = labelables.label_id)
72.          

SubPlan (for Index Scan)

73. 0.000 0.000 ↓ 0.0

Result (cost=0.00..0.01 rows=1 width=32) (actual rows= loops=)

74.          

SubPlan (for Aggregate)

75. 0.000 0.000 ↓ 0.0

Result (cost=0.00..0.01 rows=1 width=32) (actual rows= loops=)

76. 0.000 0.000 ↓ 0.0

Aggregate (cost=277.30..277.31 rows=1 width=32) (actual rows= loops=)

77. 0.000 0.000 ↓ 0.0

Seq Scan on product_images (cost=0.00..277.25 rows=3 width=101) (actual rows= loops=)

  • Filter: (products.id = product_id)
78.          

SubPlan (for Aggregate)

79. 0.000 0.000 ↓ 0.0

Result (cost=0.00..0.01 rows=1 width=32) (actual rows= loops=)

80. 0.000 0.000 ↓ 0.0

Aggregate (cost=4.91..4.92 rows=1 width=32) (actual rows= loops=)

81. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=0.43..4.90 rows=1 width=32) (actual rows= loops=)

82. 0.000 0.000 ↓ 0.0

Index Only Scan using product_suppliers_product_id_supplier_id_unique on product_suppliers (cost=0.28..2.50 rows=1 width=4) (actual rows= loops=)

  • Index Cond: (product_id = products.id)
83. 0.000 0.000 ↓ 0.0

Index Scan using suppliers_pkey on suppliers (cost=0.14..2.38 rows=1 width=36) (actual rows= loops=)

  • Index Cond: (id = product_suppliers.supplier_id)
84.          

SubPlan (for Index Scan)

85. 0.000 0.000 ↓ 0.0

Result (cost=0.00..0.01 rows=1 width=32) (actual rows= loops=)

86.          

SubPlan (for Aggregate)

87. 0.000 0.000 ↓ 0.0

Result (cost=0.00..0.01 rows=1 width=32) (actual rows= loops=)

88. 0.000 0.000 ↓ 0.0

Aggregate (cost=91.41..91.42 rows=1 width=32) (actual rows= loops=)

89. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=3.70..91.39 rows=1 width=41) (actual rows= loops=)

  • Join Filter: (products_stores.store_id = stores.id)
90. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=3.70..90.11 rows=1 width=9) (actual rows= loops=)

91. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=3.27..82.01 rows=1 width=13) (actual rows= loops=)

92. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=2.71..77.94 rows=1 width=13) (actual rows= loops=)

93. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=2.14..73.86 rows=1 width=13) (actual rows= loops=)

94. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=1.71..65.76 rows=1 width=13) (actual rows= loops=)

95. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=1.15..47.91 rows=1 width=13) (actual rows= loops=)

96. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=0.71..41.53 rows=1 width=12) (actual rows= loops=)

97. 0.000 0.000 ↓ 0.0

Index Scan using products_stores_store_id_product_id_unique on products_stores (cost=0.28..33.44 rows=1 width=12) (actual rows= loops=)

  • Index Cond: (product_id = products.id)
98. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.43..8.09 rows=1 width=8) (actual rows= loops=)

99. 0.000 0.000 ↓ 0.0

Index Scan using product_attribute_integer_values_product_id_index on product_attribute_integer_values eav_integer_min_order_qty_1 (cost=0.29..3.50 rows=1 width=12) (actual rows= loops=)

  • Index Cond: ((product_id = products_stores.product_id) AND (product_id = products.id))
  • Filter: (store_id = products_stores.store_id)
100. 0.000 0.000 ↓ 0.0

Index Scan using attributes_pkey on attributes attributes_11 (cost=0.14..2.37 rows=1 width=4) (actual rows= loops=)

  • Index Cond: (id = eav_integer_min_order_qty_1.attribute_id)
  • Filter: (((code)::text = 'min_order_qty'::text) AND ((scope)::text = 'product_store'::text))
101. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.43..6.37 rows=1 width=9) (actual rows= loops=)

102. 0.000 0.000 ↓ 0.0

Index Scan using product_attribute_boolean_values_store_id_index on product_attribute_boolean_values eav_boolean_in_range_1 (cost=0.29..2.51 rows=1 width=13) (actual rows= loops=)

  • Index Cond: (store_id = products_stores.store_id)
  • Filter: ((product_id = products.id) AND (product_id = products_stores.product_id))
103. 0.000 0.000 ↓ 0.0

Index Scan using attributes_pkey on attributes attributes_10 (cost=0.14..2.00 rows=1 width=4) (actual rows= loops=)

  • Index Cond: (id = eav_boolean_in_range_1.attribute_id)
  • Filter: (((code)::text = 'in_range'::text) AND ((scope)::text = 'product_store'::text))
104. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.56..17.85 rows=1 width=8) (actual rows= loops=)

105. 0.000 0.000 ↓ 0.0

Index Scan using product_attribute_string_values_product_id_index on product_attribute_string_values eav_string_status_1 (cost=0.42..15.52 rows=3 width=12) (actual rows= loops=)

  • Index Cond: ((product_id = products_stores.product_id) AND (product_id = products.id))
  • Filter: (store_id = products_stores.store_id)
106. 0.000 0.000 ↓ 0.0

Index Scan using attributes_pkey on attributes attributes_9 (cost=0.14..0.62 rows=1 width=4) (actual rows= loops=)

  • Index Cond: (id = eav_string_status_1.attribute_id)
  • Filter: (((code)::text = 'status'::text) AND ((scope)::text = 'product_store'::text))
107. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.43..8.09 rows=1 width=8) (actual rows= loops=)

108. 0.000 0.000 ↓ 0.0

Index Scan using product_attribute_integer_values_product_id_index on product_attribute_integer_values eav_integer_min_days_of_coverage_1 (cost=0.29..3.50 rows=1 width=12) (actual rows= loops=)

  • Index Cond: ((product_id = products_stores.product_id) AND (product_id = products.id))
  • Filter: (store_id = products_stores.store_id)
109. 0.000 0.000 ↓ 0.0

Index Scan using attributes_pkey on attributes attributes_15 (cost=0.14..2.37 rows=1 width=4) (actual rows= loops=)

  • Index Cond: (id = eav_integer_min_days_of_coverage_1.attribute_id)
  • Filter: (((code)::text = 'min_days_of_coverage'::text) AND ((scope)::text = 'product_store'::text))
110. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.56..4.07 rows=1 width=8) (actual rows= loops=)

111. 0.000 0.000 ↓ 0.0

Index Scan using product_attribute_float_values_store_id_index on product_attribute_float_values eav_float_unit_cost_price_1 (cost=0.42..2.64 rows=1 width=12) (actual rows= loops=)

  • Index Cond: (store_id = products_stores.store_id)
  • Filter: ((product_id = products.id) AND (product_id = products_stores.product_id))
112. 0.000 0.000 ↓ 0.0

Index Scan using attributes_pkey on attributes attributes_14 (cost=0.14..0.79 rows=1 width=4) (actual rows= loops=)

  • Index Cond: (id = eav_float_unit_cost_price_1.attribute_id)
  • Filter: (((code)::text = 'unit_cost_price'::text) AND ((scope)::text = 'product_store'::text))
113. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.56..4.07 rows=1 width=8) (actual rows= loops=)

114. 0.000 0.000 ↓ 0.0

Index Scan using product_attribute_float_values_store_id_index on product_attribute_float_values eav_float_unit_sell_price_1 (cost=0.42..2.64 rows=1 width=12) (actual rows= loops=)

  • Index Cond: (store_id = products_stores.store_id)
  • Filter: ((product_id = products.id) AND (product_id = products_stores.product_id))
115. 0.000 0.000 ↓ 0.0

Index Scan using attributes_pkey on attributes attributes_13 (cost=0.14..0.79 rows=1 width=4) (actual rows= loops=)

  • Index Cond: (id = eav_float_unit_sell_price_1.attribute_id)
  • Filter: (((code)::text = 'unit_sell_price'::text) AND ((scope)::text = 'product_store'::text))
116. 0.000 0.000 ↓ 0.0

Nested Loop (cost=0.43..8.09 rows=1 width=8) (actual rows= loops=)

117. 0.000 0.000 ↓ 0.0

Index Scan using product_attribute_integer_values_product_id_index on product_attribute_integer_values eav_integer_max_order_qty_1 (cost=0.29..3.50 rows=1 width=12) (actual rows= loops=)

  • Index Cond: ((product_id = products_stores.product_id) AND (product_id = products.id))
  • Filter: (store_id = products_stores.store_id)
118. 0.000 0.000 ↓ 0.0

Index Scan using attributes_pkey on attributes attributes_12 (cost=0.14..2.37 rows=1 width=4) (actual rows= loops=)

  • Index Cond: (id = eav_integer_max_order_qty_1.attribute_id)
  • Filter: (((code)::text = 'max_order_qty'::text) AND ((scope)::text = 'product_store'::text))
119. 0.000 0.000 ↓ 0.0

Seq Scan on stores (cost=0.00..1.18 rows=8 width=36) (actual rows= loops=)

120.          

SubPlan (for Seq Scan)

121. 0.000 0.000 ↓ 0.0

Result (cost=0.00..0.01 rows=1 width=32) (actual rows= loops=)

122.          

SubPlan (for Aggregate)

123. 0.000 0.000 ↓ 0.0

Result (cost=0.00..0.01 rows=1 width=32) (actual rows= loops=)

124. 0.000 0.000 ↓ 0.0

Aggregate (cost=8.57..8.58 rows=1 width=32) (actual rows= loops=)

125. 0.000 0.000 ↓ 0.0

Nested Loop Left Join (cost=0.56..8.54 rows=2 width=32) (actual rows= loops=)

126. 0.000 0.000 ↓ 0.0

Index Only Scan using product_categories_product_id_category_id_unique on product_categories (cost=0.29..3.52 rows=2 width=4) (actual rows= loops=)

  • Index Cond: (product_id = products.id)
127. 0.000 0.000 ↓ 0.0

Index Scan using categories_pkey on categories (cost=0.27..2.50 rows=1 width=36) (actual rows= loops=)

  • Index Cond: (id = product_categories.category_id)
128.          

SubPlan (for Index Scan)

129. 0.000 0.000 ↓ 0.0

Result (cost=0.00..0.01 rows=1 width=32) (actual rows= loops=)

130.          

SubPlan (for Aggregate)

131. 0.000 0.000 ↓ 0.0

Result (cost=0.00..0.01 rows=1 width=32) (actual rows= loops=)