Query time 0.00234
JSON explain
{
"query_block": {
"select_id": 1,
"cost_info": {
"query_cost": "281.15"
},
"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": 100,
"rows_produced_per_join": 100,
"filtered": "100.00",
"using_index": true,
"cost_info": {
"read_cost": "21.15",
"eval_cost": "20.00",
"prefix_cost": "41.15",
"data_read_per_join": "1K"
},
"used_columns": [
"product_id",
"category_id",
"link_type"
],
"attached_condition": "(`webmarco`.`cscart_products_categories`.`product_id` in (356117,359227,359292,350167,350940,352035,352746,354264,350874,351272,353847,354164,356786,359059,350490,354138,355700,356771,358492,350153,350877,354373,350107,353043,355763,356235,356729,356882,354807,355854,349681,350191,351952,352553,357881,359100,350711,351238,351466,351490,351956,353017,353063,355767,350028,351230,353612,356950,357344,358081,353584,355704,358368,353613,351326,351854,353449,355920,358883,351893,351902,351906,354434,356635,356894,358817,353894,355224,358402,354579,355858,357962,350556,353124,352870,353751,357281,357870,352738,356044,358751,357842,359236,350769,352961,354903,357746,350988,351112,352338,352879,353501,353630,354298,357826,353453,354602,358074,350409,352863))"
}
},
{
"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",
"webmarco.cscart_products_categories.product_id"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 100,
"filtered": "100.00",
"cost_info": {
"read_cost": "100.00",
"eval_cost": "20.00",
"prefix_cost": "161.15",
"data_read_per_join": "1K"
},
"used_columns": [
"product_id",
"category_id",
"position"
]
}
},
{
"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": [
"webmarco.cscart_products_categories.category_id"
],
"rows_examined_per_scan": 1,
"rows_produced_per_join": 5,
"filtered": "5.00",
"cost_info": {
"read_cost": "100.00",
"eval_cost": "1.00",
"prefix_cost": "281.15",
"data_read_per_join": "29K"
},
"used_columns": [
"category_id",
"usergroup_ids",
"status",
"storefront_id"
],
"attached_condition": "((`webmarco`.`cscart_categories`.`storefront_id` in (0,1)) and ((`webmarco`.`cscart_categories`.`usergroup_ids` = '') or find_in_set(0,`webmarco`.`cscart_categories`.`usergroup_ids`) or find_in_set(1,`webmarco`.`cscart_categories`.`usergroup_ids`)) and (`webmarco`.`cscart_categories`.`status` in ('A','H')))"
}
}
]
}
}
}
Result
product_id |
category_ids |
position |
349681 |
2916M |
|
350028 |
2916M |
|
350107 |
2916M |
|
350153 |
2916M |
|
350167 |
2916M |
|
350191 |
2916M |
|
350409 |
2913M |
|
350490 |
2913M |
|
350556 |
2913M |
|
350711 |
2920M |
|
350769 |
2920M |
|
350874 |
2920M |
|
350877 |
2920M |
|
350940 |
2920M |
|
350988 |
2920M |
|
351112 |
2920M |
|
351230 |
2916M |
|
351238 |
2916M |
|
351272 |
2916M |
|
351326 |
2916M |
|
351466 |
2916M |
|
351490 |
2920M |
|
351854 |
2916M |
|
351893 |
2916M |
|
351902 |
2916M |
|
351906 |
2916M |
|
351952 |
2916M |
|
351956 |
2916M |
|
352035 |
2916M |
|
352338 |
2916M |
|
352553 |
2916M |
|
352738 |
2916M |
|
352746 |
2916M |
|
352863 |
3408M |
|
352870 |
3408M |
|
352879 |
3105M |
|
352961 |
3408M |
|
353017 |
3105M |
|
353043 |
3105M |
|
353063 |
3408M |
|
353124 |
3105M |
|
353449 |
3105M |
|
353453 |
3105M |
|
353501 |
3105M |
|
353584 |
3105M |
|
353612 |
3408M |
|
353613 |
3408M |
|
353630 |
3105M |
|
353751 |
3105M |
|
353847 |
3105M |
|
353894 |
3408M |
|
354138 |
3408M |
|
354164 |
3408M |
|
354264 |
3105M |
|
354298 |
3408M |
|
354373 |
2916M |
|
354434 |
2916M |
|
354579 |
3105M |
|
354602 |
2916M |
|
354807 |
2916M |
|
354903 |
2920M |
|
355224 |
2920M |
|
355700 |
2916M |
|
355704 |
2916M |
|
355763 |
2916M |
|
355767 |
2916M |
|
355854 |
2916M |
|
355858 |
2916M |
|
355920 |
2916M |
|
356044 |
2916M |
|
356117 |
2916M |
|
356235 |
2916M |
|
356635 |
2916M |
|
356729 |
3105M |
|
356771 |
3105M |
|
356786 |
3105M |
|
356882 |
3105M |
|
356894 |
3105M |
|
356950 |
3105M |
|
357281 |
2920M |
|
357344 |
2920M |
|
357746 |
2920M |
|
357826 |
2920M |
|
357842 |
2920M |
|
357870 |
2920M |
|
357881 |
2920M |
|
357962 |
2920M |
|
358074 |
2920M |
|
358081 |
2920M |
|
358368 |
2916M |
|
358402 |
2916M |
|
358492 |
2916M |
|
358751 |
2916M |
|
358817 |
2916M |
|
358883 |
2916M |
|
359059 |
2916M |
|
359100 |
2920M |
|
359227 |
2920M |
|
359236 |
2920M |
|
359292 |
2920M |
|