Query time 0.01731
JSON explain
{
"query_block": {
"select_id": 1,
"cost_info": {
"query_cost": "31.44"
},
"ordering_operation": {
"using_filesort": true,
"grouping_operation": {
"using_temporary_table": true,
"using_filesort": false,
"nested_loop": [
{
"table": {
"table_name": "companies",
"access_type": "range",
"possible_keys": [
"PRIMARY"
],
"key": "PRIMARY",
"used_key_parts": [
"company_id"
],
"key_length": "4",
"rows_examined_per_scan": 5,
"rows_produced_per_join": 0,
"filtered": "12.50",
"cost_info": {
"read_cost": "2.20",
"eval_cost": "0.06",
"prefix_cost": "2.26",
"data_read_per_join": "3K"
},
"used_columns": [
"company_id",
"status",
"company"
],
"attached_condition": "((`nuie_scalesta_net`.`companies`.`status` = 'A') and (`nuie_scalesta_net`.`companies`.`company_id` in (2,8,9,10,0)))"
}
},
{
"table": {
"table_name": "cscart_categories",
"access_type": "range",
"possible_keys": [
"PRIMARY",
"c_status",
"p_category_id"
],
"key": "PRIMARY",
"used_key_parts": [
"category_id"
],
"key_length": "3",
"rows_examined_per_scan": 15,
"rows_produced_per_join": 0,
"filtered": "4.00",
"using_join_buffer": "hash join",
"cost_info": {
"read_cost": "4.19",
"eval_cost": "0.04",
"prefix_cost": "6.50",
"data_read_per_join": "1002"
},
"used_columns": [
"category_id",
"usergroup_ids",
"status",
"storefront_id"
],
"attached_condition": "((`nuie_scalesta_net`.`cscart_categories`.`category_id` in (7195,7196,7222,7251,7252,7253,7254,7284,7285,7286,7287,7316,7317,7330,7331)) and ((`nuie_scalesta_net`.`cscart_categories`.`usergroup_ids` = '') or (0 <> find_in_set(0,`nuie_scalesta_net`.`cscart_categories`.`usergroup_ids`)) or (0 <> find_in_set(1,`nuie_scalesta_net`.`cscart_categories`.`usergroup_ids`))) and (`nuie_scalesta_net`.`cscart_categories`.`status` in ('A','H')) and (`nuie_scalesta_net`.`cscart_categories`.`storefront_id` in (0,1)))"
}
},
{
"table": {
"table_name": "products_categories",
"access_type": "ref",
"possible_keys": [
"PRIMARY",
"pt"
],
"key": "PRIMARY",
"used_key_parts": [
"category_id"
],
"key_length": "3",
"ref": [
"nuie_scalesta_net.cscart_categories.category_id"
],
"rows_examined_per_scan": 117,
"rows_produced_per_join": 44,
"filtered": "100.00",
"using_index": true,
"cost_info": {
"read_cost": "0.11",
"eval_cost": "4.41",
"prefix_cost": "11.02",
"data_read_per_join": "705"
},
"used_columns": [
"product_id",
"category_id"
]
}
},
{
"table": {
"table_name": "products",
"access_type": "eq_ref",
"possible_keys": [
"PRIMARY",
"age_verification",
"status",
"idx_parent_product_id",
"my_supplier_id",
"supplier_access_time",
"products_rf_product_code_index",
"products_rf_manufacturer_code_index"
],
"key": "PRIMARY",
"used_key_parts": [
"product_id"
],
"key_length": "3",
"ref": [
"nuie_scalesta_net.products_categories.product_id"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 2,
"filtered": "5.00",
"cost_info": {
"read_cost": "11.03",
"eval_cost": "0.22",
"prefix_cost": "26.46",
"data_read_per_join": "10K"
},
"used_columns": [
"product_id",
"product_type",
"status",
"company_id",
"usergroup_ids",
"parent_product_id",
"rf_stop_update_price",
"rf_stop_update_amount",
"rf_stop_update_status"
],
"attached_condition": "((`nuie_scalesta_net`.`products`.`company_id` = `nuie_scalesta_net`.`companies`.`company_id`) and (`nuie_scalesta_net`.`products`.`parent_product_id` = 0) and ((`nuie_scalesta_net`.`products`.`usergroup_ids` = '') or (0 <> find_in_set(0,`nuie_scalesta_net`.`products`.`usergroup_ids`)) or (0 <> find_in_set(1,`nuie_scalesta_net`.`products`.`usergroup_ids`))) and (`nuie_scalesta_net`.`products`.`status` = 'A') and (`nuie_scalesta_net`.`products`.`product_type` <> 'D'))"
}
},
{
"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": [
"nuie_scalesta_net.products_categories.product_id",
"const"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 2,
"filtered": "100.00",
"cost_info": {
"read_cost": "0.55",
"eval_cost": "0.22",
"prefix_cost": "27.23",
"data_read_per_join": "8K"
},
"used_columns": [
"product_id",
"lang_code",
"product"
]
}
},
{
"table": {
"table_name": "prices",
"access_type": "ref",
"possible_keys": [
"usergroup",
"product_id",
"lower_limit",
"usergroup_id"
],
"key": "usergroup",
"used_key_parts": [
"product_id"
],
"key_length": "3",
"ref": [
"nuie_scalesta_net.products_categories.product_id"
],
"rows_examined_per_scan": 16,
"rows_produced_per_join": 3,
"filtered": "9.92",
"cost_info": {
"read_cost": "0.56",
"eval_cost": "0.36",
"prefix_cost": "31.44",
"data_read_per_join": "87"
},
"used_columns": [
"product_id",
"price",
"percentage_discount",
"lower_limit",
"usergroup_id"
],
"attached_condition": "((`nuie_scalesta_net`.`prices`.`lower_limit` = 1) and (`nuie_scalesta_net`.`prices`.`usergroup_id` in (0,0,1)))"
}
}
]
}
}
}
}
Result
| product_id |
product |
company_name |
price |
product_type |
parent_product_id |
rf_stop_update_price |
rf_stop_update_amount |
rf_stop_update_status |
| 97272 |
BAB057-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97273 |
BAB057S-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97274 |
BAB058-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97275 |
BAB058S-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97276 |
BAB062-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97277 |
BAB062B-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97278 |
BAB062BS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97279 |
BAB062F-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97280 |
BAB062FS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97281 |
BAB062GM-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97282 |
BAB062GMS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97283 |
BAB062IG-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97284 |
BAB062IGS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97285 |
BAB062KG-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97286 |
BAB062KGS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97287 |
BAB062M-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97288 |
BAB062MS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97289 |
BAB062MW-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97290 |
BAB062MWS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97291 |
BAB062PG-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97292 |
BAB062PGS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97293 |
BAB062R-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97294 |
BAB062RS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97295 |
BAB062S-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97296 |
BAB063-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97297 |
BAB063S-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97298 |
BAB064-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97299 |
BAB064B-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97300 |
BAB064BS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97301 |
BAB064F-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97302 |
BAB064FS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97303 |
BAB064GM-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97304 |
BAB064GMS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97305 |
BAB064IG-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97306 |
BAB064IGS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97307 |
BAB064KG-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97308 |
BAB064KGS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97309 |
BAB064M-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97310 |
BAB064MS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97311 |
BAB064PG-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97312 |
BAB064PGS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97313 |
BAB064R-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97314 |
BAB064RS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97315 |
BAB064S-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97316 |
BAB070-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97317 |
BAB070B-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97318 |
BAB070BS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97319 |
BAB070F-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97320 |
BAB070FS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97321 |
BAB070GM-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97322 |
BAB070GMS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97323 |
BAB070IG-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97324 |
BAB070IGS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97325 |
BAB070KG-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97326 |
BAB070KGS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97327 |
BAB070M-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97328 |
BAB070MS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97329 |
BAB070PG-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97330 |
BAB070PGS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97331 |
BAB070R-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97332 |
BAB070RS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97333 |
BAB070S-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97334 |
BAB071-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97335 |
BAB071S-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97336 |
BAB072-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97337 |
BAB072S-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97338 |
BAB073-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97339 |
BAB073B-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97340 |
BAB073BS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97341 |
BAB073F-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97342 |
BAB073FS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97343 |
BAB073GM-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97344 |
BAB073GMS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97345 |
BAB073IG-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97346 |
BAB073IGS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97347 |
BAB073KG-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97348 |
BAB073KGS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97349 |
BAB073M-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97350 |
BAB073MS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97351 |
BAB073PG-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97352 |
BAB073PGS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97353 |
BAB073R-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97354 |
BAB073RS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97355 |
BAB073S-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97356 |
BAB074-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97357 |
BAB074S-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97358 |
BAB075-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97359 |
BAB075B-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97360 |
BAB075BS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97361 |
BAB075F-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97362 |
BAB075FS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97363 |
BAB075GM-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97364 |
BAB075GMS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97365 |
BAB075IG-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97366 |
BAB075IGS-M |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |
| 97367 |
BAB075KG-P |
Roxor |
0.00000000 |
P |
0 |
N |
N |
N |