SELECT 
  category_id, 
  parent_id 
FROM 
  cscart_categories 
WHERE 
  parent_id IN(
    22738, 22741, 22745, 22743, 22739, 22744, 
    22756, 22751, 22749, 22748, 22740, 
    22753, 22758, 22750, 22757, 22747, 
    22746, 22742, 22755, 22737, 22752, 
    22736, 22754
  ) 
  AND category_id != 1

Query time 0.00005

JSON explain

{
  "query_block": {
    "select_id": 1,
    "nested_loop": [
      {
        "table": {
          "table_name": "cscart_categories",
          "access_type": "range",
          "possible_keys": ["PRIMARY", "parent", "p_category_id"],
          "key": "parent",
          "key_length": "3",
          "used_key_parts": ["parent_id"],
          "rows": 23,
          "filtered": 100,
          "index_condition": "cscart_categories.parent_id in (22738,22741,22745,22743,22739,22744,22756,22751,22749,22748,22740,22753,22758,22750,22757,22747,22746,22742,22755,22737,22752,22736,22754)",
          "attached_condition": "cscart_categories.category_id <> 1"
        }
      }
    ]
  }
}