Query time 0.00077
JSON explain
{
"query_block": {
"select_id": 1,
"cost_info": {
"query_cost": "0.37"
},
"ordering_operation": {
"using_filesort": true,
"nested_loop": [
{
"table": {
"table_name": "cscart_attachments",
"access_type": "ref",
"possible_keys": [
"object_type",
"type"
],
"key": "object_type",
"used_key_parts": [
"object_type",
"object_id"
],
"key_length": "95",
"ref": [
"const",
"const"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 0,
"filtered": "5.00",
"cost_info": {
"read_cost": "0.25",
"eval_cost": "0.01",
"prefix_cost": "0.35",
"data_read_per_join": "97"
},
"used_columns": [
"attachment_id",
"object_type",
"object_id",
"type",
"position",
"filename",
"filesize",
"usergroup_ids",
"status",
"url",
"on_server"
],
"attached_condition": "((`dev_yourmart_co_bw`.`cscart_attachments`.`type` = 'C') and ((`dev_yourmart_co_bw`.`cscart_attachments`.`usergroup_ids` = '') or (0 <> find_in_set(0,`dev_yourmart_co_bw`.`cscart_attachments`.`usergroup_ids`)) or (0 <> find_in_set(1,`dev_yourmart_co_bw`.`cscart_attachments`.`usergroup_ids`))) and (`dev_yourmart_co_bw`.`cscart_attachments`.`status` = 'A'))"
}
},
{
"table": {
"table_name": "cscart_attachment_descriptions",
"access_type": "eq_ref",
"possible_keys": [
"PRIMARY"
],
"key": "PRIMARY",
"used_key_parts": [
"attachment_id",
"lang_code"
],
"key_length": "9",
"ref": [
"dev_yourmart_co_bw.cscart_attachments.attachment_id",
"const"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 0,
"filtered": "100.00",
"cost_info": {
"read_cost": "0.01",
"eval_cost": "0.01",
"prefix_cost": "0.37",
"data_read_per_join": "39"
},
"used_columns": [
"attachment_id",
"lang_code",
"description"
]
}
}
]
}
}
}
Result
attachment_id |
object_type |
object_id |
type |
position |
filename |
filesize |
usergroup_ids |
status |
url |
on_server |
description |
189 |
category_icon |
274 |
C |
100 |
home-appliance.png |
10789 |
0 |
A |
|
Y |
category_icon_data |