SELECT 
  category_id, 
  parent_id 
FROM 
  cscart_categories 
WHERE 
  parent_id IN(
    166, 245, 372, 250, 219, 521, 228, 558, 
    577, 658, 661, 664
  ) 
  AND category_id != 264

Query time 0.00084

JSON explain

{
  "query_block": {
    "select_id": 1,
    "cost_info": {
      "query_cost": "37.21"
    },
    "table": {
      "table_name": "cscart_categories",
      "access_type": "range",
      "possible_keys": [
        "PRIMARY",
        "parent",
        "p_category_id"
      ],
      "key": "parent",
      "used_key_parts": [
        "parent_id"
      ],
      "key_length": "3",
      "rows_examined_per_scan": 76,
      "rows_produced_per_join": 76,
      "filtered": "100.00",
      "index_condition": "(`softwarepirmam_hewadelivard_cscart_4`.`cscart_categories`.`parent_id` in (166,245,372,250,219,521,228,558,577,658,661,664))",
      "cost_info": {
        "read_cost": "29.61",
        "eval_cost": "7.60",
        "prefix_cost": "37.21",
        "data_read_per_join": "238K"
      },
      "used_columns": [
        "category_id",
        "parent_id"
      ],
      "attached_condition": "(`softwarepirmam_hewadelivard_cscart_4`.`cscart_categories`.`category_id` <> 264)"
    }
  }
}

Result

category_id parent_id
167 166
234 166
170 166
320 166
174 166
322 166
328 166
329 166
350 166
351 166
378 166
513 166
423 166
600 166
493 219
494 219
496 219
497 219
498 219
499 219
500 219
501 219
502 219
503 219
504 219
507 219
330 228
331 228
229 228
230 228
231 228
232 228
332 245
333 245
334 245
246 245
247 245
249 245
248 245
612 250
371 250
336 250
304 250
308 250
380 250
400 250
401 250
402 250
458 250
553 250
649 250
656 250
663 250
453 372
461 372
384 372
583 372
434 372
572 372
466 372
548 372
552 372
566 372
587 372
522 521
534 521
538 521
545 521
628 558
473 577
578 577
616 577
621 577
629 577
639 577
650 577
662 577
659 658
660 658