Query time 0.00060
JSON explain
{
"query_block": {
"select_id": 1,
"cost_info": {
"query_cost": "6.80"
},
"ordering_operation": {
"using_temporary_table": true,
"using_filesort": true,
"cost_info": {
"sort_cost": "4.00"
},
"nested_loop": [
{
"table": {
"table_name": "wpa",
"access_type": "ref",
"possible_keys": [
"PRIMARY"
],
"key": "PRIMARY",
"used_key_parts": [
"product_id"
],
"key_length": "3",
"ref": [
"const"
],
"rows_examined_per_scan": 4,
"rows_produced_per_join": 4,
"filtered": "100.00",
"cost_info": {
"read_cost": "1.00",
"eval_cost": "0.40",
"prefix_cost": "1.40",
"data_read_per_join": "64"
},
"used_columns": [
"warehouse_id",
"product_id",
"amount"
]
}
},
{
"table": {
"table_name": "sl",
"access_type": "eq_ref",
"possible_keys": [
"PRIMARY"
],
"key": "PRIMARY",
"used_key_parts": [
"store_location_id"
],
"key_length": "3",
"ref": [
"dev_yourmart_co_bw.wpa.warehouse_id"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 4,
"filtered": "100.00",
"cost_info": {
"read_cost": "1.00",
"eval_cost": "0.40",
"prefix_cost": "2.80",
"data_read_per_join": "3K"
},
"used_columns": [
"store_location_id",
"position",
"status",
"main_destination_id",
"pickup_destinations_ids",
"store_type",
"shipping_destinations_ids"
]
}
}
]
}
}
}
Result
warehouse_id |
amount |
store_type |
position |
main_destination_id |
pickup_destinations_ids |
shipping_destinations_ids |
status |
8 |
37 |
W |
13 |
12 |
0 |
13,16,12,19,18,14,17,1 |
A |
9 |
19 |
W |
23 |
11 |
0 |
11,15,20 |
A |
24 |
12 |
W |
116 |
20 |
0 |
20 |
A |