Query time 0.06126
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": 255,
"filtered": 0.691103399,
"attached_condition": "pfv.feature_id in (20695,20466,20467,24444,23622,23623,21665,24836,24980,21385,24865,24866,23536,23537,21666,20040) and pfv.product_id in (3286,3872,3871,43825,35731,23261,47656,48998,1895,47657,47654,47984,35249,1412,5455) and pfv.lang_code = 'vi'",
"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 = 'vi'"
}
}
]
}
}
Result
feature_id |
product_id |
variant_id |
position |
variant |
20040 |
5455 |
70084 |
0 |
Trắng trơn |
20466 |
3872 |
71590 |
0 |
Vàng |
20467 |
3871 |
71597 |
0 |
Mẫu 7 |
20695 |
3286 |
72338 |
0 |
Vietnam Mixed |
21385 |
1895 |
74802 |
0 |
Gỗ Thông |
21665 |
23261 |
75763 |
0 |
Trọn bộ |
21666 |
1412 |
75769 |
0 |
Cốc không chân |
23536 |
35249 |
81679 |
1 |
Túi laptop 13 inch |
23537 |
35249 |
81684 |
4 |
Màu đen |
23622 |
35731 |
81910 |
1 |
Mèo cái nằm |
23623 |
35731 |
81913 |
1 |
Đỏ |
24444 |
43825 |
85255 |
1 |
Trà xanh Cao Bồ 100g + Hồng trà Vị Xuyên 50g |
24836 |
47654 |
86606 |
1 |
Mẫu vẽ hoa sen ngẫu nhiên |
24836 |
47656 |
86606 |
1 |
Mẫu vẽ hoa sen ngẫu nhiên |
24836 |
47657 |
86606 |
1 |
Mẫu vẽ hoa sen ngẫu nhiên |
24865 |
47984 |
86706 |
1 |
Rồng bố |
24866 |
47984 |
86714 |
4 |
Vàng |
24980 |
48998 |
87124 |
0 |
Da tổng hợp |