Query time 0.00332
JSON explain
{
"query_block": {
"select_id": 1,
"cost_info": {
"query_cost": "4.00"
},
"ordering_operation": {
"using_temporary_table": true,
"using_filesort": true,
"nested_loop": [
{
"table": {
"table_name": "mdi",
"access_type": "ALL",
"possible_keys": [
"PRIMARY"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 1,
"filtered": "100.00",
"cost_info": {
"read_cost": "0.25",
"eval_cost": "0.10",
"prefix_cost": "0.35",
"data_read_per_join": "336"
},
"used_columns": [
"mdi_id",
"tag",
"is_faq",
"is_open",
"status",
"position",
"position_on_page",
"item_type",
"filling_type",
"filling_data"
],
"attached_condition": "(`s2cart`.`mdi`.`status` = 'A')"
}
},
{
"table": {
"table_name": "item_settings",
"access_type": "eq_ref",
"possible_keys": [
"PRIMARY"
],
"key": "PRIMARY",
"used_key_parts": [
"item_id",
"object_type"
],
"key_length": "156",
"ref": [
"s2cart.mdi.mdi_id",
"const"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 1,
"filtered": "100.00",
"cost_info": {
"read_cost": "0.25",
"eval_cost": "0.10",
"prefix_cost": "0.70",
"data_read_per_join": "168"
},
"used_columns": [
"item_id",
"object_type",
"status",
"is_global"
],
"attached_condition": "(`s2cart`.`item_settings`.`status` = 'A')"
}
},
{
"table": {
"table_name": "global_links_include",
"access_type": "ref",
"possible_keys": [
"object_id",
"item_id"
],
"key": "object_id",
"used_key_parts": [
"object_id",
"object_type"
],
"key_length": "156",
"ref": [
"const",
"const"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 1,
"filtered": "100.00",
"cost_info": {
"read_cost": "1.00",
"eval_cost": "0.10",
"prefix_cost": "1.80",
"data_read_per_join": "168"
},
"used_columns": [
"id",
"object_id",
"object_type",
"item_id",
"link_type"
],
"attached_condition": "(<if>(found_match(global_links_include), ((`s2cart`.`item_settings`.`is_global` = 'Y') or (`s2cart`.`global_links_include`.`object_id` is not null)), true) and <if>(is_not_null_compl(global_links_include), ((`s2cart`.`global_links_include`.`item_id` = `s2cart`.`mdi`.`mdi_id`) and (`s2cart`.`global_links_include`.`link_type` = 'I')), true))"
}
},
{
"table": {
"table_name": "global_links_exclude",
"access_type": "ref",
"possible_keys": [
"object_id",
"item_id"
],
"key": "object_id",
"used_key_parts": [
"object_id",
"object_type"
],
"key_length": "156",
"ref": [
"const",
"const"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 1,
"filtered": "100.00",
"not_exists": true,
"cost_info": {
"read_cost": "1.00",
"eval_cost": "0.10",
"prefix_cost": "2.90",
"data_read_per_join": "168"
},
"used_columns": [
"id",
"object_id",
"object_type",
"item_id",
"link_type"
],
"attached_condition": "(<if>(found_match(global_links_exclude), (`s2cart`.`global_links_exclude`.`object_id` is null), true) and <if>(is_not_null_compl(global_links_exclude), ((`s2cart`.`global_links_exclude`.`item_id` = `s2cart`.`mdi`.`mdi_id`) and (`s2cart`.`global_links_exclude`.`link_type` = 'E')), true))"
}
},
{
"table": {
"table_name": "mdid",
"access_type": "eq_ref",
"possible_keys": [
"PRIMARY"
],
"key": "PRIMARY",
"used_key_parts": [
"mdi_id",
"lang_code"
],
"key_length": "10",
"ref": [
"s2cart.mdi.mdi_id",
"const"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 1,
"filtered": "100.00",
"cost_info": {
"read_cost": "1.00",
"eval_cost": "0.10",
"prefix_cost": "4.00",
"data_read_per_join": "792"
},
"used_columns": [
"mdi_id",
"lang_code",
"title",
"description"
],
"attached_condition": "(0 <> if((`s2cart`.`mdi`.`item_type` = 'elements'),(trim(`s2cart`.`mdid`.`description`) <> ''),(trim(`s2cart`.`mdid`.`title`) <> '')))"
}
}
]
}
}
}