SELECT 
  product_id, 
  amount 
FROM 
  cscart_warehouses_sum_products_amount 
WHERE 
  1 
  AND product_id IN (
    51232, 12, 51238, 51237, 51236, 51235, 
    51234, 51233, 51289, 51288, 51287, 
    51286, 51285, 51284, 51283, 8, 56, 81, 
    11, 4, 51361, 30, 51362, 51363, 51364, 
    51365, 31, 51366, 51367, 51368, 51369, 
    46, 51370, 51371, 51372, 51373, 51452, 
    51453
  )

Query time 0.00047

JSON explain

{
  "query_block": {
    "select_id": 1,
    "cost_info": {
      "query_cost": "45.06"
    },
    "table": {
      "table_name": "cscart_warehouses_sum_products_amount",
      "access_type": "range",
      "possible_keys": [
        "PRIMARY"
      ],
      "key": "PRIMARY",
      "used_key_parts": [
        "product_id"
      ],
      "key_length": "3",
      "rows_examined_per_scan": 79,
      "rows_produced_per_join": 79,
      "filtered": "100.00",
      "index_condition": "(`test_uchur_k`.`cscart_warehouses_sum_products_amount`.`product_id` in (51232,12,51238,51237,51236,51235,51234,51233,51289,51288,51287,51286,51285,51284,51283,8,56,81,11,4,51361,30,51362,51363,51364,51365,31,51366,51367,51368,51369,46,51370,51371,51372,51373,51452,51453))",
      "cost_info": {
        "read_cost": "37.16",
        "eval_cost": "7.90",
        "prefix_cost": "45.06",
        "data_read_per_join": "1K"
      },
      "used_columns": [
        "product_id",
        "amount"
      ]
    }
  }
}

Result

product_id amount
4 15
4 15
8 3
8 3
11 100
11 100
12 3
12 3
30 4
30 4
31 3
31 3
46 16
46 16
56 103
56 103
81 31
81 31
51232 5
51232 5
51233 6
51233 6
51234 3
51234 3
51235 2
51235 2
51236 3
51236 3
51237 1
51237 1
51238 1
51238 1
51283 4
51283 4
51284 6
51284 6
51285 3
51285 3
51286 1
51286 1
51287 3
51287 3
51288 3
51288 3
51289 3
51289 3
51361 4
51361 4
51362 6
51362 6
51363 6
51363 6
51364 3
51364 3
51365 1
51365 1
51366 4
51366 4
51367 4
51367 4
51368 3
51368 3
51369 2
51369 2
51370 18
51370 18
51371 25
51371 25
51372 15
51372 15
51373 13
51373 13
51452 8
51452 8
51453 10
51453 10