Query time 0.03316
JSON explain
{
"query_block": {
"select_id": 1,
"nested_loop": [
{
"table": {
"table_name": "pfv",
"access_type": "range",
"possible_keys": [
"PRIMARY",
"fl",
"variant_id",
"lang_code",
"product_id",
"fpl",
"idx_product_feature_variant_id"
],
"key": "idx_product_feature_variant_id",
"key_length": "12",
"used_key_parts": ["product_id", "feature_id", "lang_code"],
"rows": 170,
"filtered": 0.036140408,
"attached_condition": "pfv.feature_id in (23741,21910,22568,24655,23316,22367,23730,20202,23272,22578,21213,24090,24201) and pfv.product_id in (36717,1064,2249,46273,32368,353,36295,4806,31941,2260,2165,40506,41230) and pfv.lang_code = 'en'",
"using_index": true
}
},
{
"table": {
"table_name": "fv",
"access_type": "eq_ref",
"possible_keys": ["PRIMARY", "feature_id"],
"key": "PRIMARY",
"key_length": "3",
"used_key_parts": ["variant_id"],
"ref": ["dev_db.pfv.variant_id"],
"rows": 1,
"filtered": 100,
"attached_condition": "fv.feature_id = pfv.feature_id"
}
},
{
"table": {
"table_name": "fvd",
"access_type": "eq_ref",
"possible_keys": ["PRIMARY"],
"key": "PRIMARY",
"key_length": "9",
"used_key_parts": ["variant_id", "lang_code"],
"ref": ["dev_db.pfv.variant_id", "const"],
"rows": 1,
"filtered": 100,
"index_condition": "fvd.lang_code = 'en'"
}
}
]
}
}
Result
feature_id |
product_id |
variant_id |
position |
variant |
22367 |
353 |
78422 |
0 |
Brown - Without strap |
21910 |
1064 |
76692 |
0 |
Orange Flower painting "Stop waiting for tomorrow, start now" |
21213 |
2165 |
74209 |
0 |
Orange |
22568 |
2249 |
79217 |
2 |
RADERMECKER |
22578 |
2260 |
79248 |
0 |
RADERMECKER |
20202 |
4806 |
70690 |
0 |
Size 36 (24cm) |
23272 |
31941 |
80719 |
1 |
360g |
23316 |
32368 |
80885 |
2 |
Vintage green |
23730 |
36295 |
82372 |
1 |
Light brown |
23741 |
36717 |
82416 |
2 |
Yellow |
24090 |
40506 |
83933 |
1 |
50g |
24201 |
41230 |
84325 |
1 |
Orange |
24655 |
46273 |
86037 |
3 |
Black |