Query time 0.00383
JSON explain
{
"query_block": {
"select_id": 1,
"cost_info": {
"query_cost": "9.91"
},
"grouping_operation": {
"using_filesort": false,
"nested_loop": [
{
"table": {
"table_name": "cscart_master_products_storefront_min_price",
"access_type": "system",
"possible_keys": [
"PRIMARY"
],
"rows_examined_per_scan": 0,
"rows_produced_per_join": 1,
"filtered": "0.00",
"const_row_not_found": true,
"cost_info": {
"read_cost": "0.00",
"eval_cost": "0.10",
"prefix_cost": "0.00",
"data_read_per_join": "16"
},
"used_columns": [
"storefront_id",
"product_id",
"price"
]
}
},
{
"table": {
"table_name": "cscart_product_prices",
"access_type": "range",
"possible_keys": [
"usergroup",
"product_id",
"lower_limit",
"usergroup_id",
"idx_product_prices_usergroup_limit",
"idx_prices_discount_lookup",
"idx_prices_min_calc",
"idx_prices_usergroup_lookup",
"idx_prices_usergroup_product"
],
"key": "idx_prices_discount_lookup",
"used_key_parts": [
"product_id",
"lower_limit"
],
"key_length": "6",
"rows_examined_per_scan": 48,
"rows_produced_per_join": 9,
"filtered": "20.00",
"using_index": true,
"cost_info": {
"read_cost": "8.95",
"eval_cost": "0.96",
"prefix_cost": "9.91",
"data_read_per_join": "230"
},
"used_columns": [
"product_id",
"price",
"percentage_discount",
"lower_limit",
"usergroup_id"
],
"attached_condition": "((`cscart_db`.`cscart_product_prices`.`lower_limit` = 1) and (`cscart_db`.`cscart_product_prices`.`product_id` in (70149,69350,69997,65553,65832,65096,67762,68110,67730,68008,68009,68052,68065,65122,68039,68071,68085,68086,68101,64976,67769,68057,68058,69972,19741,19744,19748,27363,27368,27370,68038,68089,68099,69999,19742,19743,19745,19746,19747,19749,19750,19751,19752,19753,19754,19755,27337,27339)) and (`cscart_db`.`cscart_product_prices`.`usergroup_id` in (0,1)))"
}
}
]
}
}
}
Result
| product_id |
price |
| 19741 |
540.000000 |
| 19742 |
540.000000 |
| 19743 |
540.000000 |
| 19744 |
540.000000 |
| 19745 |
540.000000 |
| 19746 |
540.000000 |
| 19747 |
540.000000 |
| 19748 |
540.000000 |
| 19749 |
540.000000 |
| 19750 |
540.000000 |
| 19751 |
540.000000 |
| 19752 |
540.000000 |
| 19753 |
540.000000 |
| 19754 |
540.000000 |
| 19755 |
540.000000 |
| 27337 |
417.900000 |
| 27339 |
417.900000 |
| 27363 |
698.600000 |
| 27368 |
1297.400000 |
| 27370 |
1596.800000 |
| 64976 |
236.550000 |
| 65096 |
852.000000 |
| 65122 |
449.100000 |
| 65553 |
324.350000 |
| 65832 |
254.150000 |
| 67730 |
66.930000 |
| 67762 |
150.000000 |
| 67769 |
476.000000 |
| 68008 |
110.000000 |
| 68009 |
270.000000 |
| 68038 |
111.750000 |
| 68039 |
166.250000 |
| 68052 |
168.750000 |
| 68057 |
676.600000 |
| 68058 |
696.500000 |
| 68065 |
51.000000 |
| 68071 |
129.500000 |
| 68085 |
800.000000 |
| 68086 |
696.500000 |
| 68089 |
191.250000 |
| 68099 |
162.500000 |
| 68101 |
120.000000 |
| 68110 |
115.500000 |
| 69350 |
450.000000 |
| 69972 |
750.000000 |
| 69997 |
599.000000 |
| 69999 |
764.100000 |
| 70149 |
200.000000 |