Query time 0.00143
JSON explain
{
"query_block": {
"select_id": 1,
"cost_info": {
"query_cost": "16.63"
},
"nested_loop": [
{
"table": {
"table_name": "v",
"access_type": "range",
"possible_keys": [
"PRIMARY",
"fl",
"product_id",
"fpl",
"idx_product_feature_variant_id"
],
"key": "idx_product_feature_variant_id",
"used_key_parts": [
"product_id",
"feature_id"
],
"key_length": "6",
"rows_examined_per_scan": 18,
"rows_produced_per_join": 18,
"filtered": "100.00",
"using_index": true,
"cost_info": {
"read_cost": "2.23",
"eval_cost": "1.80",
"prefix_cost": "4.03",
"data_read_per_join": "13K"
},
"used_columns": [
"feature_id",
"product_id",
"variant_id"
],
"attached_condition": "((`cscartdb`.`v`.`feature_id` = 1071) and (`cscartdb`.`v`.`product_id` in ('29796','29803','29802','29801','29800','29799','29798','29797','29795','29794','29793','29792','29791','29790','29789','29788','29787','26651')))"
}
},
{
"table": {
"table_name": "vd",
"access_type": "eq_ref",
"possible_keys": [
"PRIMARY"
],
"key": "PRIMARY",
"used_key_parts": [
"variant_id",
"lang_code"
],
"key_length": "9",
"ref": [
"cscartdb.v.variant_id",
"const"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 18,
"filtered": "100.00",
"cost_info": {
"read_cost": "4.50",
"eval_cost": "1.80",
"prefix_cost": "10.33",
"data_read_per_join": "54K"
},
"used_columns": [
"variant_id",
"variant",
"lang_code"
]
}
},
{
"table": {
"table_name": "vf",
"access_type": "eq_ref",
"possible_keys": [
"PRIMARY"
],
"key": "PRIMARY",
"used_key_parts": [
"variant_id"
],
"key_length": "3",
"ref": [
"cscartdb.v.variant_id"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 18,
"filtered": "100.00",
"cost_info": {
"read_cost": "4.50",
"eval_cost": "1.80",
"prefix_cost": "16.63",
"data_read_per_join": "20K"
},
"used_columns": [
"variant_id",
"color",
"position"
]
}
}
]
}
}
Result
variant_id |
product_id |
variant |
position |
color |
3986 |
26651 |
Teal |
1 |
#ffffff |
3981 |
29787 |
Aqua |
12 |
#ffffff |
3988 |
29788 |
Peachy |
13 |
#ffffff |
3984 |
29789 |
Rose |
14 |
#ffffff |
3976 |
29790 |
Pink |
11 |
#ffffff |
3989 |
29791 |
Lime |
15 |
#ffffff |
3983 |
29792 |
Eggplant |
10 |
#ffffff |
3972 |
29793 |
Chartreuse |
16 |
#ffffff |
3977 |
29794 |
Blue |
17 |
#ffffff |
3985 |
29795 |
Navy |
2 |
#ffffff |
3979 |
29796 |
Red |
3 |
#ffffff |
3973 |
29797 |
Lilac |
4 |
#ffffff |
3974 |
29798 |
Black |
5 |
#ffffff |
3975 |
29799 |
Snow |
6 |
#ffffff |
3982 |
29800 |
Fuschia |
7 |
#ffffff |
3980 |
29801 |
Mint |
8 |
#ffffff |
3987 |
29802 |
Coral |
9 |
#ffffff |
3978 |
29803 |
Olive |
0 |
#ffffff |