Query time 0.00097
JSON explain
{
"query_block": {
"select_id": 1,
"cost_info": {
"query_cost": "14.52"
},
"ordering_operation": {
"using_temporary_table": true,
"using_filesort": true,
"nested_loop": [
{
"table": {
"table_name": "q_categories",
"access_type": "ref",
"possible_keys": [
"c_status",
"parent",
"id_path"
],
"key": "parent",
"used_key_parts": [
"parent_id"
],
"key_length": "3",
"ref": [
"const"
],
"rows_examined_per_scan": 12,
"rows_produced_per_join": 0,
"filtered": "0.42",
"cost_info": {
"read_cost": "12.00",
"eval_cost": "0.01",
"prefix_cost": "14.40",
"data_read_per_join": "135"
},
"used_columns": [
"category_id",
"parent_id",
"id_path",
"usergroup_ids",
"status",
"position",
"is_trash",
"ab__lc_catalog_image_control"
],
"attached_condition": "(((`portal`.`q_categories`.`usergroup_ids` = '') or find_in_set(0,`portal`.`q_categories`.`usergroup_ids`) or find_in_set(1,`portal`.`q_categories`.`usergroup_ids`)) and (`portal`.`q_categories`.`status` = 'A') and (`portal`.`q_categories`.`id_path` like '300/%'))"
}
},
{
"table": {
"table_name": "q_category_descriptions",
"access_type": "eq_ref",
"possible_keys": [
"PRIMARY"
],
"key": "PRIMARY",
"used_key_parts": [
"category_id",
"lang_code"
],
"key_length": "9",
"ref": [
"portal.q_categories.category_id",
"const"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 0,
"filtered": "100.00",
"cost_info": {
"read_cost": "0.05",
"eval_cost": "0.01",
"prefix_cost": "14.46",
"data_read_per_join": "155"
},
"used_columns": [
"category_id",
"lang_code",
"category"
]
}
},
{
"table": {
"table_name": "q_seo_names",
"access_type": "ref",
"possible_keys": [
"PRIMARY",
"dispatch"
],
"key": "PRIMARY",
"used_key_parts": [
"object_id",
"type",
"dispatch",
"lang_code"
],
"key_length": "206",
"ref": [
"portal.q_categories.category_id",
"const",
"const",
"const"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 0,
"filtered": "100.00",
"cost_info": {
"read_cost": "0.05",
"eval_cost": "0.01",
"prefix_cost": "14.52",
"data_read_per_join": "86"
},
"used_columns": [
"name",
"object_id",
"type",
"dispatch",
"path",
"lang_code"
]
}
}
]
}
}
}
Result
category_id |
parent_id |
id_path |
category |
position |
status |
seo_name |
seo_path |
ab__lc_catalog_image_control |
375 |
300 |
300/375 |
Interior Accessories |
10 |
A |
interior-accessories |
300 |
none |
376 |
300 |
300/376 |
Exterior Accessories |
20 |
A |
exterior-accessories |
300 |
none |
377 |
300 |
300/377 |
Lighting & Equipments |
30 |
A |
lighting-and-equipments |
300 |
none |
390 |
300 |
300/390 |
Compressors |
40 |
A |
compressors |
300 |
none |
410 |
300 |
300/410 |
Car Care |
50 |
A |
car-care |
300 |
none |
430 |
300 |
300/430 |
Air Freshener |
60 |
A |
air-freshener |
300 |
none |
534 |
300 |
300/534 |
Car Body Covers |
70 |
A |
car-body-covers |
300 |
none |
572 |
300 |
300/572 |
Scooter & Bikes Accessories |
80 |
A |
scooter-and-bikes-accessories |
300 |
none |
573 |
300 |
300/573 |
Oils & Fluids |
90 |
A |
oils-and-fluids |
300 |
none |
574 |
300 |
300/574 |
Jump Starters |
100 |
A |
jump-starters |
300 |
none |
575 |
300 |
300/575 |
Tire & Wheel Accessories |
110 |
A |
tire-and-wheel-accessories |
300 |
none |
581 |
300 |
300/581 |
Tools & Equipment |
120 |
A |
tools-and-equipment |
300 |
none |
588 |
300 |
300/588 |
Body Repair & Paints |
130 |
A |
body-repair-and-paints |
300 |
none |
606 |
300 |
300/606 |
Automotive Electronics |
140 |
A |
automotive-electronics |
300 |
none |