Query time 0.00143
JSON explain
{
"query_block": {
"select_id": 1,
"table": {
"table_name": "cscart_products_categories",
"access_type": "range",
"possible_keys": ["PRIMARY", "pt"],
"key": "pt",
"key_length": "3",
"used_key_parts": ["product_id"],
"rows": 24,
"filtered": 100,
"index_condition": "cscart_products_categories.product_id in (1431,360,1479,1478,414,1866,1427,788,1084,1407,1903,1452,1453,538,1864,1863,1461,1199,1943,1901,1200,1212,1939,1211)"
},
"table": {
"table_name": "product_position_source",
"access_type": "eq_ref",
"possible_keys": ["PRIMARY", "pt"],
"key": "PRIMARY",
"key_length": "6",
"used_key_parts": ["category_id", "product_id"],
"ref": ["const", "bacpvdev_db.cscart_products_categories.product_id"],
"rows": 1,
"filtered": 100
},
"table": {
"table_name": "cscart_categories",
"access_type": "eq_ref",
"possible_keys": ["PRIMARY", "c_status", "p_category_id"],
"key": "PRIMARY",
"key_length": "3",
"used_key_parts": ["category_id"],
"ref": ["bacpvdev_db.cscart_products_categories.category_id"],
"rows": 1,
"filtered": 100,
"attached_condition": "cscart_categories.storefront_id in (0,1) and (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')"
}
}
}
Result
product_id |
category_ids |
position |
360 |
17M |
|
414 |
17M |
|
538 |
17M |
|
788 |
17M |
|
1084 |
17M |
|
1199 |
8M |
|
1200 |
8M |
|
1211 |
8M |
|
1212 |
8M |
|
1407 |
7M |
0 |
1427 |
7M |
0 |
1431 |
7M |
0 |
1452 |
7M |
0 |
1453 |
7M |
0 |
1461 |
20M |
|
1478 |
17M |
|
1479 |
17M |
|
1863 |
8M |
|
1864 |
8M |
|
1866 |
17M |
|
1901 |
8M |
|
1903 |
17M |
|
1939 |
8M |
|
1943 |
8M |
|