SELECT 
  product_id, 
  amount 
FROM 
  cscart_warehouses_sum_products_amount 
WHERE 
  1 
  AND product_id IN (
    51480, 51479, 51494, 51495, 132, 112, 
    3, 78, 2, 77, 87, 66, 22421, 22424, 22290, 
    50981, 50982, 133, 45, 143, 50983, 51416, 
    51043, 51421, 51471, 51413, 51057, 
    51472, 51547, 51470, 51500, 51412
  )

Query time 0.00084

JSON explain

{
  "query_block": {
    "select_id": 1,
    "cost_info": {
      "query_cost": "34.11"
    },
    "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": 58,
      "rows_produced_per_join": 58,
      "filtered": "100.00",
      "index_condition": "(`test_uchur_k`.`cscart_warehouses_sum_products_amount`.`product_id` in (51480,51479,51494,51495,132,112,3,78,2,77,87,66,22421,22424,22290,50981,50982,133,45,143,50983,51416,51043,51421,51471,51413,51057,51472,51547,51470,51500,51412))",
      "cost_info": {
        "read_cost": "28.31",
        "eval_cost": "5.80",
        "prefix_cost": "34.11",
        "data_read_per_join": "928"
      },
      "used_columns": [
        "product_id",
        "amount"
      ]
    }
  }
}

Result

product_id amount
2 120
2 120
3 8
3 8
45 5
45 5
66 9
66 9
77 3
77 3
78 3
78 3
87 9
87 9
112 10
112 10
132 53
132 53
133 10
133 10
143 6
143 6
22290 1
22290 1
22421 4
22421 4
22424 2
22424 2
50981 8
50981 8
50982 1
50982 1
50983 1
50983 1
51043 4
51043 4
51057 1
51057 1
51412 3
51412 3
51413 1
51413 1
51416 1
51416 1
51421 2
51421 2
51470 4
51470 4
51471 8
51471 8
51472 6
51472 6
51479 148
51479 148
51480 147
51480 147
51494 52
51494 52
51495 52
51495 52
51500 5
51500 5
51547 10
51547 10