SELECT 
  q_product_prices.product_id, 
  MIN(
    IF(
      q_product_prices.percentage_discount = 0, 
      q_product_prices.price, 
      q_product_prices.price - (
        q_product_prices.price * q_product_prices.percentage_discount
      )/ 100
    )
  ) AS price 
FROM 
  q_product_prices 
WHERE 
  q_product_prices.product_id IN (
    29201, 29202, 29203, 29204, 29205, 29206, 
    29207, 29208, 29209, 29210, 29211, 
    29212, 29213, 29214, 29215, 29216, 
    29218, 29219, 29220, 29221, 29222, 
    29223, 29224, 29225, 29226, 29227, 
    29228, 29229, 29230, 29231, 29232, 
    29233
  ) 
  AND q_product_prices.lower_limit = 1 
  AND q_product_prices.usergroup_id IN (0, 1) 
GROUP BY 
  q_product_prices.product_id

Query time 0.00213

JSON explain

{
  "query_block": {
    "select_id": 1,
    "cost_info": {
      "query_cost": "86.61"
    },
    "grouping_operation": {
      "using_filesort": false,
      "table": {
        "table_name": "q_product_prices",
        "access_type": "range",
        "possible_keys": [
          "usergroup",
          "product_id",
          "lower_limit",
          "usergroup_id"
        ],
        "key": "product_id",
        "used_key_parts": [
          "product_id"
        ],
        "key_length": "3",
        "rows_examined_per_scan": 39,
        "rows_produced_per_join": 7,
        "filtered": "19.99",
        "index_condition": "(`portal`.`q_product_prices`.`product_id` in (29201,29202,29203,29204,29205,29206,29207,29208,29209,29210,29211,29212,29213,29214,29215,29216,29218,29219,29220,29221,29222,29223,29224,29225,29226,29227,29228,29229,29230,29231,29232,29233))",
        "cost_info": {
          "read_cost": "85.05",
          "eval_cost": "1.56",
          "prefix_cost": "86.61",
          "data_read_per_join": "187"
        },
        "used_columns": [
          "product_id",
          "price",
          "percentage_discount",
          "lower_limit",
          "usergroup_id"
        ],
        "attached_condition": "((`portal`.`q_product_prices`.`lower_limit` = 1) and (`portal`.`q_product_prices`.`usergroup_id` in (0,1)))"
      }
    }
  }
}

Result

product_id price
29201 76.000000
29202 62.000000
29203 87.000000
29204 261.000000
29205 84.000000
29206 296.000000
29207 76.000000
29208 289.000000
29209 315.000000
29210 408.000000
29211 219.000000
29212 26.000000
29213 48.000000
29214 322.000000
29215 25.000000
29216 23.000000
29218 648.000000
29219 87.000000
29220 61.000000
29221 152.000000
29222 71.000000
29223 88.000000
29224 125.000000
29225 125.000000
29226 311.000000
29227 170.000000
29228 61.000000
29229 131.000000
29230 179.000000
29231 89.000000
29232 129.000000
29233 269.000000