SELECT 
  category_id, 
  parent_id 
FROM 
  cscart_categories 
WHERE 
  parent_id IN(
    307, 331, 319, 327, 321, 311, 332, 320, 
    328, 322, 324, 312, 333, 323, 622, 334, 
    326, 329, 325, 689, 335, 330, 336, 690, 
    338, 337, 316, 679, 340, 395, 339, 539, 
    310, 707
  )

Query time 0.00050

JSON explain

{
  "query_block": {
    "select_id": 1,
    "cost_info": {
      "query_cost": "53.72"
    },
    "table": {
      "table_name": "cscart_categories",
      "access_type": "ALL",
      "possible_keys": [
        "parent"
      ],
      "rows_examined_per_scan": 233,
      "rows_produced_per_join": 49,
      "filtered": "21.03",
      "cost_info": {
        "read_cost": "43.92",
        "eval_cost": "9.80",
        "prefix_cost": "53.72",
        "data_read_per_join": "127K"
      },
      "used_columns": [
        "category_id",
        "parent_id"
      ],
      "attached_condition": "(`ea201_diorama`.`cscart_categories`.`parent_id` in (307,331,319,327,321,311,332,320,328,322,324,312,333,323,622,334,326,329,325,689,335,330,336,690,338,337,316,679,340,395,339,539,310,707))"
    }
  }
}

Result

category_id parent_id
327 326
319 316
321 323
331 319
328 326
322 323
320 316
332 319
323 316
324 323
333 319
329 326
325 323
326 316
334 319
330 326
335 319
689 316
336 319
690 316
338 319
337 319
340 319
339 319