Query time 0.00123
JSON explain
{
"query_block": {
"select_id": 1,
"cost_info": {
"query_cost": "2.84"
},
"nested_loop": [
{
"table": {
"table_name": "a",
"access_type": "range",
"possible_keys": [
"type"
],
"key": "type",
"used_key_parts": [
"type"
],
"key_length": "9",
"rows_examined_per_scan": 4,
"rows_produced_per_join": 0,
"filtered": "20.00",
"index_condition": "(`poscentr_upgrade422`.`a`.`type` in ('ips','ipr','ipb'))",
"cost_info": {
"read_cost": "2.48",
"eval_cost": "0.08",
"prefix_cost": "2.56",
"data_read_per_join": "249"
},
"used_columns": [
"item_id",
"ip_from",
"ip_to",
"type",
"status"
],
"attached_condition": "((`poscentr_upgrade422`.`a`.`ip_from` <= 'd849d94a') and (`poscentr_upgrade422`.`a`.`ip_to` >= 'd849d94a') and (`poscentr_upgrade422`.`a`.`status` = 'A'))"
}
},
{
"table": {
"table_name": "b",
"access_type": "eq_ref",
"possible_keys": [
"PRIMARY"
],
"key": "PRIMARY",
"used_key_parts": [
"item_id",
"type",
"lang_code"
],
"key_length": "18",
"ref": [
"poscentr_upgrade422.a.item_id",
"poscentr_upgrade422.a.type",
"const"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 0,
"filtered": "100.00",
"cost_info": {
"read_cost": "0.20",
"eval_cost": "0.08",
"prefix_cost": "2.84",
"data_read_per_join": "25"
},
"used_columns": [
"item_id",
"type",
"reason",
"lang_code"
]
}
}
]
}
}