SELECT 
  cscart_categories.category_id, 
  cscart_categories.parent_id, 
  cscart_categories.id_path, 
  cscart_category_descriptions.category, 
  cscart_categories.position, 
  cscart_categories.status, 
  cscart_categories.company_id, 
  cscart_categories.storefront_id, 
  cscart_seo_names.name as seo_name, 
  cscart_seo_names.path as seo_path, 
  cscart_categories.ab__lc_catalog_image_control, 
  cscart_category_descriptions.mega_m_category_banner_url, 
  cscart_category_descriptions.mega_m_category_svg_icon 
FROM 
  cscart_categories 
  LEFT JOIN cscart_category_descriptions ON cscart_categories.category_id = cscart_category_descriptions.category_id 
  AND cscart_category_descriptions.lang_code = 'en' 
  LEFT JOIN cscart_seo_names ON cscart_seo_names.object_id = cscart_categories.category_id 
  AND cscart_seo_names.type = 'c' 
  AND cscart_seo_names.dispatch = '' 
  AND cscart_seo_names.lang_code = 'en' 
WHERE 
  1 = 1 
  AND (
    cscart_categories.usergroup_ids = '' 
    OR FIND_IN_SET(
      0, cscart_categories.usergroup_ids
    ) 
    OR FIND_IN_SET(
      1, cscart_categories.usergroup_ids
    )
  ) 
  AND cscart_categories.status IN ('A') 
  AND cscart_categories.id_path LIKE '317/%' 
  AND cscart_categories.category_id != 264 
  AND cscart_categories.parent_id != 264 
  AND cscart_categories.storefront_id IN (0, 1) 
ORDER BY 
  cscart_categories.is_trash asc, 
  cscart_categories.position asc, 
  cscart_category_descriptions.category asc

Query time 0.00146

JSON explain

{
  "query_block": {
    "select_id": 1,
    "cost": 0.11580434,
    "filesort": {
      "sort_key": "cscart_categories.is_trash, cscart_categories.position, cscart_category_descriptions.category",
      "temporary_table": {
        "nested_loop": [
          {
            "table": {
              "table_name": "cscart_categories",
              "access_type": "range",
              "possible_keys": [
                "PRIMARY",
                "c_status",
                "parent",
                "id_path",
                "p_category_id"
              ],
              "key": "id_path",
              "key_length": "767",
              "used_key_parts": ["id_path"],
              "loops": 1,
              "rows": 34,
              "cost": 0.0394908,
              "filtered": 100,
              "index_condition": "cscart_categories.id_path like '317/%' and cscart_categories.category_id <> 264",
              "attached_condition": "(cscart_categories.usergroup_ids = '' or find_in_set(0,cscart_categories.usergroup_ids) or find_in_set(1,cscart_categories.usergroup_ids)) and cscart_categories.`status` = 'A' and cscart_categories.parent_id <> 264 and cscart_categories.storefront_id in (0,1)"
            }
          },
          {
            "table": {
              "table_name": "cscart_category_descriptions",
              "access_type": "eq_ref",
              "possible_keys": ["PRIMARY"],
              "key": "PRIMARY",
              "key_length": "9",
              "used_key_parts": ["category_id", "lang_code"],
              "ref": ["u508912950_dev_2025.cscart_categories.category_id", "const"],
              "loops": 34,
              "rows": 1,
              "cost": 0.03696456,
              "filtered": 100,
              "attached_condition": "trigcond(cscart_category_descriptions.lang_code = 'en')"
            }
          },
          {
            "table": {
              "table_name": "cscart_seo_names",
              "access_type": "ref",
              "possible_keys": ["PRIMARY", "dispatch"],
              "key": "PRIMARY",
              "key_length": "206",
              "used_key_parts": ["object_id", "type", "dispatch", "lang_code"],
              "ref": [
                "u508912950_dev_2025.cscart_categories.category_id",
                "const",
                "const",
                "const"
              ],
              "loops": 34,
              "rows": 1,
              "cost": 0.03934898,
              "filtered": 100,
              "attached_condition": "trigcond(cscart_seo_names.`type` = 'c' and cscart_seo_names.dispatch = '' and cscart_seo_names.lang_code = 'en')"
            }
          }
        ]
      }
    }
  }
}

Result

category_id parent_id id_path category position status company_id storefront_id seo_name seo_path ab__lc_catalog_image_control mega_m_category_banner_url mega_m_category_svg_icon
476 465 317/465/476 Belts 10 A 0 0 belts-en 317/465 none
1651 1650 317/1650/1651 Boxers & Briefs 10 A 0 0 boxers-and-briefs 317/1650 none
319 317 317/319 Clothing 10 A 0 0 clothing 317 none
483 325 317/325/483 Sneakers 10 A 0 0 sneakers 317/325 none
1656 1655 317/1655/1656 Swimwear 10 A 0 0 swimwear 317/1655 none
1647 480 317/480/1647 Wallets 10 A 0 0 wallets-en 317/480 none
1648 480 317/480/1648 Crossbags & Bumbags 20 A 0 0 crossbags-and-bumbags 317/480 none
1657 1655 317/1655/1657 Flip Flops 20 A 0 0 flip-flops 317/1655 none
478 465 317/465/478 Hats 20 A 0 0 hats 317/465 none
484 325 317/325/484 Mocassins 20 A 0 0 mocassins 317/325 none
325 317 317/325 Shoes 20 A 0 0 shoes 317 none
1652 1650 317/1650/1652 Socks 20 A 0 0 socks 317/1650 none
471 319 317/319/471 Tshirts & Polos 20 A 0 0 tshirts-and-polos 317/319 none
1649 480 317/480/1649 Backpacks & Laptop Bags 30 A 0 0 backpacks-and-laptop-bags 317/480 none
480 317 317/480 Bags & Wallets 30 A 0 0 bags-and-wallets 317 none
485 325 317/325/485 Espadrilles 30 A 0 0 espadrilles 317/325 none
1653 1650 317/1650/1653 Pajamas 30 A 0 0 pajamas 317/1650 none
479 465 317/465/479 Scarves & Beanies 30 A 0 0 scarves-and-beanies 317/465 none
472 319 317/319/472 Shirts 30 A 0 0 shirts 317/319 none
1659 1655 317/1655/1659 Sliders 30 A 0 0 sliders 317/1655 none
465 317 317/465 Accessories 40 A 0 0 accessories 317 none
486 325 317/325/486 Boots 40 A 0 0 boots 317/325 none
1654 1650 317/1650/1654 Loungewear Sets 40 A 0 0 loungewear-sets 317/1650 none
473 319 317/319/473 Tracksuits 40 A 0 0 tracksuits 317/319 none
1658 480 317/480/1658 Wash Bags 40 A 0 0 wash-bags 317/480 none
474 319 317/319/474 Hoodies 50 A 0 0 hoodies 317/319 none
1655 317 317/1655 Summer 50 A 0 0 summer 317 none
481 465 317/465/481 Underwear 50 A 0 0 underwear 317/465 none
482 465 317/465/482 Gifts 60 A 0 0 gifts 317/465 none
475 319 317/319/475 Long Sleeve Tops 60 A 0 0 long-sleeve-tops 317/319 none
1597 319 317/319/1597 Jackets & Gilets 70 A 0 0 jackets-and-gilets 317/319 none
1598 319 317/319/1598 Trousers 80 A 0 0 trousers 317/319 none
1646 319 317/319/1646 Sweaters 90 A 0 0 sweaters 317/319 none