Query time 0.00517
JSON explain
{
"query_block": {
"select_id": 1,
"cost_info": {
"query_cost": "69.54"
},
"ordering_operation": {
"using_filesort": false,
"grouping_operation": {
"using_temporary_table": true,
"using_filesort": false,
"nested_loop": [
{
"table": {
"table_name": "companies",
"access_type": "ALL",
"possible_keys": [
"PRIMARY"
],
"rows_examined_per_scan": 10,
"rows_produced_per_join": 1,
"filtered": "10.00",
"cost_info": {
"read_cost": "1.46",
"eval_cost": "0.10",
"prefix_cost": "1.56",
"data_read_per_join": "6K"
},
"used_columns": [
"company_id",
"status",
"company"
],
"attached_condition": "(`softwarepirmam_hewadelivard_cscart_4`.`companies`.`status` = 'A')"
}
},
{
"table": {
"table_name": "variation_group_products",
"access_type": "range",
"possible_keys": [
"PRIMARY",
"idx_group_id"
],
"key": "idx_group_id",
"used_key_parts": [
"group_id"
],
"key_length": "3",
"rows_examined_per_scan": 72,
"rows_produced_per_join": 72,
"filtered": "100.00",
"index_condition": "(`softwarepirmam_hewadelivard_cscart_4`.`variation_group_products`.`group_id` in (45,340,273,66,219,284,161,272,158,307,268,350,115,320,65,114,116,159,160,162,297))",
"using_join_buffer": "hash join",
"cost_info": {
"read_cost": "30.46",
"eval_cost": "7.20",
"prefix_cost": "39.22",
"data_read_per_join": "1K"
},
"used_columns": [
"product_id",
"group_id"
]
}
},
{
"table": {
"table_name": "products",
"access_type": "eq_ref",
"possible_keys": [
"PRIMARY",
"status"
],
"key": "PRIMARY",
"used_key_parts": [
"product_id"
],
"key_length": "3",
"ref": [
"softwarepirmam_hewadelivard_cscart_4.variation_group_products.product_id"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 3,
"filtered": "5.00",
"cost_info": {
"read_cost": "18.00",
"eval_cost": "0.36",
"prefix_cost": "64.42",
"data_read_per_join": "15K"
},
"used_columns": [
"product_id",
"product_type",
"status",
"company_id",
"amount",
"usergroup_ids",
"tracking",
"parent_product_id"
],
"attached_condition": "((`softwarepirmam_hewadelivard_cscart_4`.`products`.`company_id` = `softwarepirmam_hewadelivard_cscart_4`.`companies`.`company_id`) and ((`softwarepirmam_hewadelivard_cscart_4`.`products`.`amount` > 0) or (`softwarepirmam_hewadelivard_cscart_4`.`products`.`tracking` = 'D')) and ((`softwarepirmam_hewadelivard_cscart_4`.`products`.`usergroup_ids` = '') or (0 <> find_in_set(0,`softwarepirmam_hewadelivard_cscart_4`.`products`.`usergroup_ids`)) or (0 <> find_in_set(1,`softwarepirmam_hewadelivard_cscart_4`.`products`.`usergroup_ids`))) and (`softwarepirmam_hewadelivard_cscart_4`.`products`.`status` = 'A') and (`softwarepirmam_hewadelivard_cscart_4`.`products`.`product_type` <> 'D'))"
}
},
{
"table": {
"table_name": "products_categories",
"access_type": "ref",
"possible_keys": [
"PRIMARY",
"pt"
],
"key": "pt",
"used_key_parts": [
"product_id"
],
"key_length": "3",
"ref": [
"softwarepirmam_hewadelivard_cscart_4.variation_group_products.product_id"
],
"rows_examined_per_scan": 2,
"rows_produced_per_join": 7,
"filtered": "100.00",
"cost_info": {
"read_cost": "1.80",
"eval_cost": "0.72",
"prefix_cost": "66.94",
"data_read_per_join": "115"
},
"used_columns": [
"product_id",
"category_id"
]
}
},
{
"table": {
"table_name": "cscart_categories",
"access_type": "eq_ref",
"possible_keys": [
"PRIMARY",
"c_status",
"p_category_id"
],
"key": "PRIMARY",
"used_key_parts": [
"category_id"
],
"key_length": "3",
"ref": [
"softwarepirmam_hewadelivard_cscart_4.products_categories.category_id"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 0,
"filtered": "5.00",
"cost_info": {
"read_cost": "1.80",
"eval_cost": "0.04",
"prefix_cost": "69.46",
"data_read_per_join": "1K"
},
"used_columns": [
"category_id",
"storefront_id",
"usergroup_ids",
"status"
],
"attached_condition": "(((`softwarepirmam_hewadelivard_cscart_4`.`cscart_categories`.`usergroup_ids` = '') or (0 <> find_in_set(0,`softwarepirmam_hewadelivard_cscart_4`.`cscart_categories`.`usergroup_ids`)) or (0 <> find_in_set(1,`softwarepirmam_hewadelivard_cscart_4`.`cscart_categories`.`usergroup_ids`))) and (`softwarepirmam_hewadelivard_cscart_4`.`cscart_categories`.`status` in ('A','H')) and (`softwarepirmam_hewadelivard_cscart_4`.`cscart_categories`.`storefront_id` in (0,1)))"
}
},
{
"table": {
"table_name": "descr1",
"access_type": "eq_ref",
"possible_keys": [
"PRIMARY",
"product_id"
],
"key": "PRIMARY",
"used_key_parts": [
"product_id",
"lang_code"
],
"key_length": "9",
"ref": [
"softwarepirmam_hewadelivard_cscart_4.variation_group_products.product_id",
"const"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 0,
"filtered": "100.00",
"cost_info": {
"read_cost": "0.05",
"eval_cost": "0.04",
"prefix_cost": "69.54",
"data_read_per_join": "1K"
},
"used_columns": [
"product_id",
"lang_code",
"product"
]
}
}
]
}
}
}
}
Result
| product_id |
amount |
product |
company_name |
variation_group_id |
product_type |
parent_product_id |
| 908 |
100 |
Xiaomi Buds 5 PRO |
Delivard Store |
45 |
P |
0 |
| 134 |
100 |
Xiaomi Buds 5 PRO |
Delivard Store |
45 |
V |
908 |
| 1142 |
499 |
Apple AirPods 4 |
Delivard Store |
65 |
V |
853 |
| 853 |
500 |
Apple AirPods 4 |
Delivard Store |
65 |
P |
0 |
| 1146 |
500 |
Apple AirPods Max |
Delivard Store |
66 |
V |
1143 |
| 1145 |
500 |
Apple AirPods Max |
Delivard Store |
66 |
V |
1143 |
| 1144 |
500 |
Apple AirPods Max |
Delivard Store |
66 |
V |
1143 |
| 1143 |
500 |
Apple AirPods Max |
Delivard Store |
66 |
P |
0 |
| 856 |
500 |
Apple AirPods Max |
Delivard Store |
66 |
V |
1143 |
| 1540 |
100 |
Samsung Galaxy Buds FE |
Delivard Store |
114 |
P |
0 |
| 1541 |
100 |
Samsung Galaxy Buds FE |
Delivard Store |
114 |
V |
1540 |
| 1542 |
100 |
Galaxy Buds 3 |
Delivard Store |
115 |
P |
0 |
| 1543 |
100 |
Galaxy Buds 3 |
Delivard Store |
115 |
V |
1542 |
| 1544 |
100 |
Samsung Galaxy Buds3 Pro |
Delivard Store |
116 |
P |
0 |
| 1545 |
100 |
Samsung Galaxy Buds3 Pro |
Delivard Store |
116 |
V |
1544 |
| 2258 |
99 |
Xiaomi Redmi Buds 6 Active |
Delivard Store |
158 |
V |
2255 |
| 2257 |
100 |
Xiaomi Redmi Buds 6 Active |
Delivard Store |
158 |
V |
2255 |
| 2256 |
100 |
Xiaomi Redmi Buds 6 Active |
Delivard Store |
158 |
V |
2255 |
| 2255 |
100 |
Xiaomi Redmi Buds 6 Active |
Delivard Store |
158 |
P |
0 |
| 2260 |
100 |
Xiaomi Redmi Buds 6 |
Delivard Store |
159 |
V |
2251 |
| 2259 |
100 |
Xiaomi Redmi Buds 6 |
Delivard Store |
159 |
V |
2251 |
| 2251 |
100 |
Xiaomi Redmi Buds 6 |
Delivard Store |
159 |
P |
0 |
| 2262 |
100 |
Xiaomi Redmi Buds 6 Pro |
Delivard Store |
160 |
V |
2252 |
| 2261 |
100 |
Xiaomi Redmi Buds 6 Pro |
Delivard Store |
160 |
V |
2252 |
| 2252 |
100 |
Xiaomi Redmi Buds 6 Pro |
Delivard Store |
160 |
P |
0 |
| 2265 |
99 |
Xiaomi Redmi Buds 6 Play |
Delivard Store |
161 |
V |
2253 |
| 2264 |
100 |
Xiaomi Redmi Buds 6 Play |
Delivard Store |
161 |
V |
2253 |
| 2263 |
100 |
Xiaomi Redmi Buds 6 Play |
Delivard Store |
161 |
V |
2253 |
| 2253 |
100 |
Xiaomi Redmi Buds 6 Play |
Delivard Store |
161 |
P |
0 |
| 2267 |
100 |
Xiaomi Redmi Buds 6 lite |
Delivard Store |
162 |
V |
2254 |
| 2266 |
100 |
Xiaomi Redmi Buds 6 lite |
Delivard Store |
162 |
V |
2254 |
| 2254 |
100 |
Xiaomi Redmi Buds 6 lite |
Delivard Store |
162 |
P |
0 |
| 2559 |
100 |
Anker Soundcore Sport X20 ANC TWS Earbuds |
Delivard Store |
219 |
P |
0 |
| 2560 |
100 |
Anker Soundcore Sport X20 ANC TWS Earbuds |
Delivard Store |
219 |
V |
2559 |
| 3663 |
100 |
Anker Soundcore Sport X20 ANC TWS Earbuds |
Delivard Store |
219 |
V |
2559 |
| 2729 |
100 |
JBL Wave Beam in Ear Earbuds |
Delivard Store |
268 |
P |
0 |
| 2730 |
100 |
JBL Wave Beam in Ear Earbuds |
Delivard Store |
268 |
V |
2729 |
| 2731 |
100 |
JBL Wave Beam in Ear Earbuds |
Delivard Store |
268 |
V |
2729 |
| 2732 |
100 |
JBL Wave Beam in Ear Earbuds |
Delivard Store |
268 |
V |
2729 |
| 2746 |
100 |
JBL Tune Beam TWS |
Delivard Store |
272 |
V |
2751 |
| 2747 |
100 |
JBL Tune Beam TWS |
Delivard Store |
272 |
V |
2751 |
| 2749 |
100 |
JBL Tune Beam TWS |
Delivard Store |
272 |
V |
2751 |
| 2750 |
100 |
JBL Tune Beam TWS |
Delivard Store |
272 |
V |
2751 |
| 2751 |
100 |
JBL Tune Beam TWS |
Delivard Store |
272 |
P |
0 |
| 2752 |
100 |
JBL Tune Flex Earphones |
Delivard Store |
273 |
P |
0 |
| 2753 |
100 |
JBL Tune Flex Earphones |
Delivard Store |
273 |
V |
2752 |
| 2754 |
100 |
JBL Tune Flex Earphones |
Delivard Store |
273 |
V |
2752 |
| 2755 |
100 |
JBL Tune Flex Earphones |
Delivard Store |
273 |
V |
2752 |
| 2756 |
100 |
JBL Tune Flex Earphones |
Delivard Store |
273 |
V |
2752 |
| 2757 |
100 |
JBL Tune Flex Earphones |
Delivard Store |
273 |
V |
2752 |
| 2822 |
100 |
Anker Soundcore Liberty 4 NC |
Delivard Store |
284 |
P |
0 |
| 2823 |
100 |
Anker Soundcore Liberty 4 NC |
Delivard Store |
284 |
V |
2822 |
| 2824 |
100 |
Anker Soundcore Liberty 4 NC |
Delivard Store |
284 |
V |
2822 |
| 2825 |
100 |
Anker Soundcore Liberty 4 NC |
Delivard Store |
284 |
V |
2822 |
| 2826 |
100 |
Anker Soundcore Liberty 4 NC |
Delivard Store |
284 |
V |
2822 |
| 2869 |
100 |
JBL T230NC TWS |
Delivard Store |
297 |
P |
0 |
| 2870 |
100 |
JBL T230NC TWS |
Delivard Store |
297 |
V |
2869 |
| 2871 |
100 |
JBL T230NC TWS |
Delivard Store |
297 |
V |
2869 |
| 2927 |
100 |
Anker Soundcore K20i TWS |
Delivard Store |
307 |
P |
0 |
| 2928 |
100 |
Anker Soundcore K20i TWS |
Delivard Store |
307 |
V |
2927 |
| 2929 |
100 |
Anker Soundcore K20i TWS |
Delivard Store |
307 |
V |
2927 |
| 3026 |
100 |
Huawei FreeBuds Pro 4 |
Delivard Store |
320 |
P |
0 |
| 3030 |
100 |
Huawei FreeBuds Pro 4 |
Delivard Store |
320 |
V |
3026 |
| 3029 |
100 |
Huawei FreeBuds Pro 4 |
Delivard Store |
320 |
V |
3026 |
| 3090 |
100 |
Anker Soundcore R50i NC TWS |
Delivard Store |
340 |
P |
0 |
| 3091 |
100 |
Anker Soundcore R50i NC TWS |
Delivard Store |
340 |
V |
3090 |
| 3092 |
100 |
Anker Soundcore R50i NC TWS |
Delivard Store |
340 |
V |
3090 |
| 3093 |
100 |
Anker Soundcore R50i NC TWS |
Delivard Store |
340 |
V |
3090 |
| 3094 |
100 |
Anker Soundcore R50i NC TWS |
Delivard Store |
340 |
V |
3090 |
| 3140 |
100 |
Anker Soundcore AeroFit TWS |
Delivard Store |
350 |
P |
0 |
| 3141 |
100 |
Anker Soundcore AeroFit TWS |
Delivard Store |
350 |
V |
3140 |