SELECT 
  category_id, 
  parent_id 
FROM 
  cscart_categories 
WHERE 
  parent_id IN(
    997, 795, 972, 167, 989, 982, 1003, 1018, 
    1011
  ) 
  AND category_id != 264

Query time 0.00065

JSON explain

{
  "query_block": {
    "select_id": 1,
    "cost_info": {
      "query_cost": "13.87"
    },
    "table": {
      "table_name": "cscart_categories",
      "access_type": "range",
      "possible_keys": [
        "PRIMARY",
        "parent",
        "p_category_id"
      ],
      "key": "parent",
      "used_key_parts": [
        "parent_id",
        "category_id"
      ],
      "key_length": "6",
      "rows_examined_per_scan": 68,
      "rows_produced_per_join": 68,
      "filtered": "100.00",
      "using_index": true,
      "cost_info": {
        "read_cost": "7.07",
        "eval_cost": "6.80",
        "prefix_cost": "13.87",
        "data_read_per_join": "177K"
      },
      "used_columns": [
        "category_id",
        "parent_id"
      ],
      "attached_condition": "((`aomnia_com`.`cscart_categories`.`parent_id` in (997,795,972,167,989,982,1003,1018,1011)) and (`aomnia_com`.`cscart_categories`.`category_id` <> 264))"
    }
  }
}

Result

category_id parent_id
165 167
168 167
169 167
170 167
334 167
969 167
970 167
971 167
796 795
797 795
798 795
799 795
800 795
801 795
1016 795
1017 795
973 972
974 972
975 972
976 972
977 972
978 972
979 972
980 972
981 972
983 982
984 982
985 982
986 982
987 982
988 982
990 989
991 989
992 989
993 989
994 989
995 989
996 989
998 997
999 997
1000 997
1001 997
1002 997
1004 1003
1005 1003
1006 1003
1007 1003
1008 1003
1009 1003
1010 1011
1012 1011
1013 1011
1014 1011
1015 1011
1019 1018
1020 1018
1021 1018
1022 1018
1023 1018
1024 1018