Query time 0.00215
JSON explain
{
"query_block": {
"select_id": 1,
"cost_info": {
"query_cost": "54.77"
},
"grouping_operation": {
"using_filesort": false,
"nested_loop": [
{
"table": {
"table_name": "cscart_products_categories",
"access_type": "range",
"possible_keys": [
"PRIMARY",
"link_type",
"pt"
],
"key": "pt",
"used_key_parts": [
"product_id"
],
"key_length": "3",
"rows_examined_per_scan": 96,
"rows_produced_per_join": 96,
"filtered": "100.00",
"using_index": true,
"cost_info": {
"read_cost": "9.89",
"eval_cost": "9.60",
"prefix_cost": "19.49",
"data_read_per_join": "1K"
},
"used_columns": [
"product_id",
"category_id",
"link_type"
],
"attached_condition": "(`nuie_scalesta_net`.`cscart_products_categories`.`product_id` in (92886,92887,92888,92889,92890,92891,93078,93080,93082,93084,93085,93086,93087,93089,93091,93093,93094,93095,93096,93097,93098,93099,93100,93101,93102,93103,93104,93105,93106,93107,93108,93109,93110,93111,93112,93113,93114,93116,93118,93120,93121,93122,93123,93124,93125,93126,93127,93128,93129,93130,93131,93132,93134,93136,93138,93139,93140,93141,93142,93143,93144,93145,93146,93147,93148,93149,93160,93161,93162,93163,93164,93165,93166,93167,93168,93169,93170,93171,93172,93173,93174,93175,93176,93177,93178,93179,93180,93181,93182,93183,93184,93185,93186,93187,93188,93189))"
}
},
{
"table": {
"table_name": "cscart_categories",
"access_type": "eq_ref",
"possible_keys": [
"PRIMARY",
"c_status",
"p_category_id"
],
"key": "PRIMARY",
"used_key_parts": [
"category_id"
],
"key_length": "3",
"ref": [
"nuie_scalesta_net.cscart_products_categories.category_id"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 4,
"filtered": "5.00",
"cost_info": {
"read_cost": "24.00",
"eval_cost": "0.48",
"prefix_cost": "53.09",
"data_read_per_join": "12K"
},
"used_columns": [
"category_id",
"usergroup_ids",
"status",
"storefront_id"
],
"attached_condition": "((`nuie_scalesta_net`.`cscart_categories`.`storefront_id` in (0,1)) and ((`nuie_scalesta_net`.`cscart_categories`.`usergroup_ids` = '') or (0 <> find_in_set(0,`nuie_scalesta_net`.`cscart_categories`.`usergroup_ids`)) or (0 <> find_in_set(1,`nuie_scalesta_net`.`cscart_categories`.`usergroup_ids`))) and (`nuie_scalesta_net`.`cscart_categories`.`status` in ('A','H')))"
}
},
{
"table": {
"table_name": "product_position_source",
"access_type": "eq_ref",
"possible_keys": [
"PRIMARY",
"pt"
],
"key": "PRIMARY",
"used_key_parts": [
"category_id",
"product_id"
],
"key_length": "6",
"ref": [
"const",
"nuie_scalesta_net.cscart_products_categories.product_id"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 4,
"filtered": "100.00",
"cost_info": {
"read_cost": "1.20",
"eval_cost": "0.48",
"prefix_cost": "54.77",
"data_read_per_join": "76"
},
"used_columns": [
"product_id",
"category_id",
"position"
]
}
}
]
}
}
}
Result
| product_id |
category_ids |
position |
| 92886 |
7192M |
0 |
| 92887 |
7192M |
0 |
| 92888 |
7192M |
0 |
| 92889 |
7192M |
0 |
| 92890 |
7192M |
0 |
| 92891 |
7192M |
0 |
| 93078 |
7192M |
0 |
| 93080 |
7192M |
0 |
| 93082 |
7192M |
0 |
| 93084 |
7192M |
0 |
| 93085 |
7192M |
0 |
| 93086 |
7192M |
0 |
| 93087 |
7192M |
0 |
| 93089 |
7192M |
0 |
| 93091 |
7192M |
0 |
| 93093 |
7192M |
0 |
| 93094 |
7192M |
0 |
| 93095 |
7192M |
0 |
| 93096 |
7192M |
0 |
| 93097 |
7192M |
0 |
| 93098 |
7192M |
0 |
| 93099 |
7192M |
0 |
| 93100 |
7192M |
0 |
| 93101 |
7192M |
0 |
| 93102 |
7192M |
0 |
| 93103 |
7192M |
0 |
| 93104 |
7192M |
0 |
| 93105 |
7192M |
0 |
| 93106 |
7192M |
0 |
| 93107 |
7192M |
0 |
| 93108 |
7192M |
0 |
| 93109 |
7192M |
0 |
| 93110 |
7192M |
0 |
| 93111 |
7192M |
0 |
| 93112 |
7192M |
0 |
| 93113 |
7192M |
0 |
| 93114 |
7192M |
0 |
| 93116 |
7192M |
0 |
| 93118 |
7192M |
0 |
| 93120 |
7192M |
0 |
| 93121 |
7192M |
0 |
| 93122 |
7192M |
0 |
| 93123 |
7192M |
0 |
| 93124 |
7192M |
0 |
| 93125 |
7192M |
0 |
| 93126 |
7192M |
0 |
| 93127 |
7192M |
0 |
| 93128 |
7192M |
0 |
| 93129 |
7192M |
0 |
| 93130 |
7192M |
0 |
| 93131 |
7192M |
0 |
| 93132 |
7192M |
0 |
| 93134 |
7192M |
0 |
| 93136 |
7192M |
0 |
| 93138 |
7192M |
0 |
| 93139 |
7192M |
0 |
| 93140 |
7192M |
0 |
| 93141 |
7192M |
0 |
| 93142 |
7192M |
0 |
| 93143 |
7192M |
0 |
| 93144 |
7192M |
0 |
| 93145 |
7192M |
0 |
| 93146 |
7192M |
0 |
| 93147 |
7192M |
0 |
| 93148 |
7192M |
0 |
| 93149 |
7192M |
0 |
| 93160 |
7192M |
0 |
| 93161 |
7192M |
0 |
| 93162 |
7192M |
0 |
| 93163 |
7192M |
0 |
| 93164 |
7192M |
0 |
| 93165 |
7192M |
0 |
| 93166 |
7192M |
0 |
| 93167 |
7192M |
0 |
| 93168 |
7192M |
0 |
| 93169 |
7192M |
0 |
| 93170 |
7192M |
0 |
| 93171 |
7192M |
0 |
| 93172 |
7192M |
0 |
| 93173 |
7192M |
0 |
| 93174 |
7192M |
0 |
| 93175 |
7192M |
0 |
| 93176 |
7192M |
0 |
| 93177 |
7192M |
0 |
| 93178 |
7192M |
0 |
| 93179 |
7192M |
0 |
| 93180 |
7192M |
0 |
| 93181 |
7192M |
0 |
| 93182 |
7192M |
0 |
| 93183 |
7192M |
0 |
| 93184 |
7192M |
0 |
| 93185 |
7192M |
0 |
| 93186 |
7192M |
0 |
| 93187 |
7192M |
0 |
| 93188 |
7192M |
0 |
| 93189 |
7192M |
0 |