Query time 0.02844
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": "PRIMARY",
"key_length": "6",
"used_key_parts": ["feature_id", "product_id"],
"rows": 248,
"filtered": 0.025230313,
"attached_condition": "pfv.feature_id in (21031,20147,21045,21028,21077,21478,21080,21073,21059,20558,19958,24317,21629,20555,23589) and pfv.product_id in (2495,4939,2470,2498,2438,1748,2435,2442,2456,3625,5726,42264,23169,3628,35485) 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 |
19958 |
5726 |
69750 |
0 |
Brown |
20147 |
4939 |
70492 |
0 |
Big Size |
20555 |
3628 |
71897 |
0 |
Set 4 |
20558 |
3625 |
71907 |
0 |
Size XL |
21028 |
2498 |
73463 |
0 |
Cafe Soap |
21031 |
2495 |
73474 |
0 |
250gr |
21045 |
2470 |
73502 |
0 |
70g |
21059 |
2456 |
73530 |
0 |
70g |
21073 |
2442 |
73574 |
0 |
10ml |
21077 |
2438 |
73582 |
0 |
10ml |
21080 |
2435 |
73588 |
0 |
10ml |
21478 |
1748 |
75181 |
0 |
Medium Size |
21629 |
23169 |
75645 |
0 |
Style 1 |
23589 |
35485 |
81817 |
1 |
100g |
24317 |
42264 |
84739 |
10 |
Rosemary |