SELECT 
  cscart_product_prices.product_id, 
  MIN(
    IF(
      cscart_product_prices.percentage_discount = 0, 
      cscart_product_prices.price, 
      cscart_product_prices.price - (
        cscart_product_prices.price * cscart_product_prices.percentage_discount
      )/ 100
    )
  ) AS price 
FROM 
  cscart_product_prices 
WHERE 
  cscart_product_prices.product_id IN (
    415240, 185498, 206442, 209099, 149369, 
    415293, 282473, 149445, 149436, 220056, 
    149383, 149377, 220029, 149449, 185470, 
    149398, 149453, 149399, 220054, 220033, 
    381767, 149373, 220036, 270167, 275684, 
    270168, 262997, 263001, 185469, 185502, 
    270264, 263000, 270378, 185490, 270170, 
    185487, 185495, 185501, 270196, 270202, 
    270231, 185473, 263002, 270377, 185464, 
    270193, 275686, 270272, 270369, 276860, 
    262999, 270169, 270226, 185472, 270370, 
    270371, 270195, 275683, 270194, 270205, 
    270171, 185463, 185475, 185491, 185488, 
    185493, 276862, 276870, 185465, 185466, 
    270227, 276871, 270204, 270373, 185468, 
    185471, 270206, 270273, 309380, 270268, 
    270225, 185499, 309377, 185474, 309382, 
    309381, 309378, 270199, 275685, 270230, 
    309379, 185467, 270229, 185482, 270379, 
    270380, 270270, 185483, 185481, 185503
  ) 
  AND cscart_product_prices.lower_limit = 1 
  AND cscart_product_prices.usergroup_id IN (0, 1) 
GROUP BY 
  cscart_product_prices.product_id

Query time 0.00168

JSON explain

{
  "query_block": {
    "select_id": 1,
    "cost_info": {
      "query_cost": "280.31"
    },
    "grouping_operation": {
      "using_filesort": false,
      "table": {
        "table_name": "cscart_product_prices",
        "access_type": "range",
        "possible_keys": [
          "usergroup",
          "product_id",
          "lower_limit",
          "usergroup_id"
        ],
        "key": "usergroup",
        "used_key_parts": [
          "product_id",
          "usergroup_id",
          "lower_limit"
        ],
        "key_length": "9",
        "rows_examined_per_scan": 200,
        "rows_produced_per_join": 200,
        "filtered": "100.00",
        "cost_info": {
          "read_cost": "240.31",
          "eval_cost": "40.00",
          "prefix_cost": "280.31",
          "data_read_per_join": "12K"
        },
        "used_columns": [
          "product_id",
          "price",
          "percentage_discount",
          "lower_limit",
          "usergroup_id"
        ],
        "attached_condition": "((`webmarco`.`cscart_product_prices`.`lower_limit` = 1) and (`webmarco`.`cscart_product_prices`.`product_id` in (415240,185498,206442,209099,149369,415293,282473,149445,149436,220056,149383,149377,220029,149449,185470,149398,149453,149399,220054,220033,381767,149373,220036,270167,275684,270168,262997,263001,185469,185502,270264,263000,270378,185490,270170,185487,185495,185501,270196,270202,270231,185473,263002,270377,185464,270193,275686,270272,270369,276860,262999,270169,270226,185472,270370,270371,270195,275683,270194,270205,270171,185463,185475,185491,185488,185493,276862,276870,185465,185466,270227,276871,270204,270373,185468,185471,270206,270273,309380,270268,270225,185499,309377,185474,309382,309381,309378,270199,275685,270230,309379,185467,270229,185482,270379,270380,270270,185483,185481,185503)) and (`webmarco`.`cscart_product_prices`.`usergroup_id` in (0,1)))"
      }
    }
  }
}

Result

product_id price
149369 73.50000000
149373 33.60000000
149377 48.30000000
149383 12.00000000
149398 24.00000000
149399 29.75000000
149436 29.00000000
149445 32.49000000
149449 24.90000000
149453 37.50000000
185463 15.75000000
185464 9.24000000
185465 9.24000000
185466 9.24000000
185467 9.24000000
185468 9.24000000
185469 9.24000000
185470 9.24000000
185471 9.24000000
185472 9.24000000
185473 9.24000000
185474 9.24000000
185475 9.24000000
185481 9.24000000
185482 9.24000000
185483 9.24000000
185487 9.24000000
185488 9.24000000
185490 9.24000000
185491 9.24000000
185493 9.24000000
185495 9.24000000
185498 9.24000000
185499 9.24000000
185501 9.24000000
185502 9.24000000
185503 9.24000000
206442 91.80000000
209099 50.15000000
220029 52.80000000
220033 63.20000000
220036 82.80000000
220054 110.40000000
220056 76.00000000
262997 20.00000000
262999 12.00000000
263000 13.00000000
263001 20.00000000
263002 23.00000000
270167 100.00000000
270168 125.00000000
270169 110.00000000
270170 135.00000000
270171 135.00000000
270193 100.00000000
270194 95.00000000
270195 75.00000000
270196 125.00000000
270199 10.00000000
270202 60.00000000
270204 80.00000000
270205 110.00000000
270206 145.00000000
270225 150.00000000
270226 120.00000000
270227 125.00000000
270229 190.00000000
270230 135.00000000
270231 125.00000000
270264 145.00000000
270268 105.00000000
270270 85.00000000
270272 110.00000000
270273 35.00000000
270369 100.00000000
270370 70.00000000
270371 180.00000000
270373 130.00000000
270377 130.00000000
270378 280.00000000
270379 180.00000000
270380 160.00000000
275683 110.00000000
275684 125.00000000
275685 120.00000000
275686 150.00000000
276860 80.00000000
276862 120.00000000
276870 5.68000000
276871 5.68000000
282473 28.50000000
309377 0.00000000
309378 0.00000000
309379 0.00000000
309380 0.00000000
309381 0.00000000
309382 0.00000000
381767 26.00000000
415240 18.20000000
415293 8.09000000