Query time 0.08157
JSON explain
{
"query_block": {
"select_id": 1,
"cost": 1205.024152,
"filesort": {
"sort_key": "descr1.product, products.product_id",
"temporary_table": {
"nested_loop": [
{
"table": {
"table_name": "companies",
"access_type": "const",
"possible_keys": ["PRIMARY"],
"key": "PRIMARY",
"key_length": "4",
"used_key_parts": ["company_id"],
"ref": ["const"],
"rows": 1,
"filtered": 100
}
},
{
"table": {
"table_name": "cscart_categories",
"access_type": "ALL",
"possible_keys": ["PRIMARY", "c_status", "p_category_id"],
"loops": 1,
"rows": 99,
"cost": 0.0269918,
"filtered": 100,
"attached_condition": "(cscart_categories.usergroup_ids = '' or find_in_set(0,cscart_categories.usergroup_ids) or find_in_set(1,cscart_categories.usergroup_ids)) and cscart_categories.`status` in ('A','H') and cscart_categories.storefront_id in (0,1)"
}
},
{
"table": {
"table_name": "products_categories",
"access_type": "ref",
"possible_keys": ["PRIMARY", "pt"],
"key": "PRIMARY",
"key_length": "3",
"used_key_parts": ["category_id"],
"ref": ["u985510652_ecartify.cscart_categories.category_id"],
"loops": 99,
"rows": 4107,
"cost": 66.77361603,
"filtered": 100
}
},
{
"table": {
"table_name": "products",
"access_type": "eq_ref",
"possible_keys": ["PRIMARY", "status", "idx_parent_product_id"],
"key": "PRIMARY",
"key_length": "3",
"used_key_parts": ["product_id"],
"ref": ["u985510652_ecartify.products_categories.product_id"],
"loops": 406593,
"rows": 1,
"cost": 367.7379133,
"filtered": 100,
"attached_condition": "products.company_id = 5 and products.parent_product_id = 0 and (products.usergroup_ids = '' or find_in_set(0,products.usergroup_ids) or find_in_set(1,products.usergroup_ids)) and products.`status` = 'A' and products.product_type <> 'D'"
}
},
{
"table": {
"table_name": "descr1",
"access_type": "eq_ref",
"possible_keys": ["PRIMARY", "product_id"],
"key": "PRIMARY",
"key_length": "9",
"used_key_parts": ["product_id", "lang_code"],
"ref": [
"u985510652_ecartify.products_categories.product_id",
"const"
],
"loops": 406593,
"rows": 1,
"cost": 377.2734013,
"filtered": 100,
"attached_condition": "trigcond(descr1.lang_code = 'en')"
}
},
{
"table": {
"table_name": "prices",
"access_type": "ref",
"possible_keys": [
"usergroup",
"product_id",
"lower_limit",
"usergroup_id"
],
"key": "usergroup",
"key_length": "3",
"used_key_parts": ["product_id"],
"ref": ["u985510652_ecartify.products_categories.product_id"],
"loops": 406593,
"rows": 1,
"cost": 393.2122292,
"filtered": 100,
"attached_condition": "prices.lower_limit = 1 and prices.usergroup_id in (0,0,1)"
}
}
]
}
}
}
}
Result
| product_id |
product |
company_name |
product_type |
parent_product_id |
| 187 |
2010 TOUR STAFF Bag 10" |
AutoZone |
P |
0 |
| 312419 |
Alex Vando Mens Golf Shirt Moisture Wicking Quick-Dry Solid Short Sleeve Polo Shirts for Men |
AutoZone |
P |
0 |
| 312881 |
BINCA Dotties Dot Art Activity Kit - On the Go, 750+ Stickers, Vehicles Mess-Free Activities, DIY Dot Sticker Art for Toddlers, Kids Travel Activities, Craft Kits & Gifts for Boys & Girls Ages 4,5,6,7 |
AutoZone |
P |
0 |
| 436374 |
Classic Backpack 265 |
AutoZone |
P |
0 |
| 441927 |
Classic Backpack 403 |
AutoZone |
P |
0 |
| 437733 |
Classic Backpack 503 |
AutoZone |
P |
0 |
| 433372 |
Classic Backpack 575 |
AutoZone |
P |
0 |
| 429338 |
Classic Backpack 708 |
AutoZone |
P |
0 |
| 404315 |
Classic Backpack 716 |
AutoZone |
P |
0 |
| 403114 |
Classic Backpack 746 |
AutoZone |
P |
0 |
| 434319 |
Classic Backpack 765 |
AutoZone |
P |
0 |
| 455492 |
Classic Backpack 789 |
AutoZone |
P |
0 |
| 457298 |
Classic Backpack 850 |
AutoZone |
P |
0 |
| 426898 |
Classic Backpack 868 |
AutoZone |
P |
0 |
| 435154 |
Classic Backpack 934 |
AutoZone |
P |
0 |
| 454872 |
Classic Backpack 983 |
AutoZone |
P |
0 |
| 429201 |
Classic Book 187 |
AutoZone |
P |
0 |
| 431252 |
Classic Book 294 |
AutoZone |
P |
0 |
| 460123 |
Classic Book 384 |
AutoZone |
P |
0 |
| 456772 |
Classic Book 388 |
AutoZone |
P |
0 |
| 447624 |
Classic Book 414 |
AutoZone |
P |
0 |
| 418357 |
Classic Book 440 |
AutoZone |
P |
0 |
| 417083 |
Classic Book 491 |
AutoZone |
P |
0 |
| 423074 |
Classic Book 556 |
AutoZone |
P |
0 |
| 422315 |
Classic Book 631 |
AutoZone |
P |
0 |
| 445550 |
Classic Book 634 |
AutoZone |
P |
0 |
| 413493 |
Classic Book 666 |
AutoZone |
P |
0 |
| 406571 |
Classic Book 714 |
AutoZone |
P |
0 |
| 419858 |
Classic Book 714 |
AutoZone |
P |
0 |
| 437062 |
Classic Book 734 |
AutoZone |
P |
0 |
| 428608 |
Classic Book 751 |
AutoZone |
P |
0 |
| 440002 |
Classic Book 776 |
AutoZone |
P |
0 |
| 420919 |
Classic Book 796 |
AutoZone |
P |
0 |
| 454421 |
Classic Book 871 |
AutoZone |
P |
0 |
| 413105 |
Classic Book 873 |
AutoZone |
P |
0 |
| 439177 |
Classic Book 900 |
AutoZone |
P |
0 |
| 437268 |
Classic Book 922 |
AutoZone |
P |
0 |
| 450216 |
Classic Book 924 |
AutoZone |
P |
0 |
| 405994 |
Classic Bottle 127 |
AutoZone |
P |
0 |
| 437380 |
Classic Bottle 231 |
AutoZone |
P |
0 |
| 438012 |
Classic Bottle 295 |
AutoZone |
P |
0 |
| 406160 |
Classic Bottle 317 |
AutoZone |
P |
0 |
| 440620 |
Classic Bottle 395 |
AutoZone |
P |
0 |
| 447721 |
Classic Bottle 418 |
AutoZone |
P |
0 |
| 416159 |
Classic Bottle 424 |
AutoZone |
P |
0 |
| 420047 |
Classic Bottle 455 |
AutoZone |
P |
0 |
| 413235 |
Classic Bottle 503 |
AutoZone |
P |
0 |
| 424041 |
Classic Bottle 565 |
AutoZone |
P |
0 |