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 '313/%' 
  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.00117

JSON explain

{
  "query_block": {
    "select_id": 1,
    "cost": 0.11865679,
    "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": 35,
              "cost": 0.04048424,
              "filtered": 100,
              "index_condition": "cscart_categories.id_path like '313/%' 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": 35,
              "rows": 1,
              "cost": 0.037859,
              "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": 35,
              "rows": 1,
              "cost": 0.04031355,
              "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
597 572 313/572/597 Essential Oils & Aromatherapy 10 A 0 0 essential-oils-and-aromatherapy 313/572 none
574 357 313/357/574 Face 10 A 0 0 face 313/357 none
357 313 313/357 Makeup 10 A 0 0 makeup 313 none
592 363 313/363/592 Perfumes 10 A 0 0 perfumes 313/363 none
582 571 313/571/582 Sun & After-Sun Care 10 A 0 0 sun-and-after-sun-care 313/571 none
587 361 313/361/587 Sun & Sea Protection 10 A 0 0 sun-and-sea-protection 313/361 none
579 359 313/359/579 Sun Protection 10 A 0 0 sun-protection 313/359 none
593 363 313/363/593 Body Mists 20 A 0 0 body-mists 313/363 none
575 357 313/357/575 Eyes 20 A 0 0 eyes 313/357 none
580 359 313/359/580 Hydrating & Moisturizing 20 A 0 0 hydrating-and-moisturizing 313/359 none
583 571 313/571/583 Hydration & Nourishment 20 A 0 0 hydration-and-nourishment 313/571 none
588 361 313/361/588 Hydration & Repair 20 A 0 0 hydration-and-repair 313/361 none
359 313 313/359 Skincare 20 A 0 0 skincare 313 none
598 572 313/572/598 Supplements & Vitamins 20 A 0 0 supplements-and-vitamins 313/572 none
571 313 313/571 Bodycare 30 A 0 0 bodycare 313 none
581 359 313/359/581 Clean Beauty 30 A 0 0 clean-beauty 313/359 none
594 363 313/363/594 Deodorants 30 A 0 0 deodorants 313/363 none
584 571 313/571/584 Exfoliation & Detox 30 A 0 0 exfoliation-and-detox 313/571 none
577 357 313/357/577 Eyebrows 30 A 0 0 eyebrows 313/357 none
599 572 313/572/599 Mind & Body Relaxation 30 A 0 0 mind-and-body-relaxation 313/572 none
589 361 313/361/589 Styling & Texture 30 A 0 0 styling-and-texture 313/361 none
590 361 313/361/590 Color Care 40 A 0 0 color-care 313/361 none
595 363 313/363/595 Gift Sets 40 A 0 0 gift-sets 313/363 none
361 313 313/361 Haircare 40 A 0 0 haircare 313 none
576 357 313/357/576 Lips 40 A 0 0 lips 313/357 none
600 572 313/572/600 Natural Remedies 40 A 0 0 natural-remedies 313/572 none
585 571 313/571/585 Targeted Treatments 40 A 0 0 targeted-treatments 313/571 none
578 357 313/357/578 Accessories 50 A 0 0 accessories 313/357 none
363 313 313/363 Fragrances 50 A 0 0 fragrances 313 none
601 572 313/572/601 Healthy Lifestyle 50 A 0 0 healthy-lifestyle 313/572 none
586 571 313/571/586 Self-Care Rituals 50 A 0 0 self-care-rituals 313/571 none
591 361 313/361/591 Specific Hair Needs 50 A 0 0 specific-hair-needs 313/361 none
596 363 313/363/596 Travel Sizes 50 A 0 0 travel-sizes 313/363 none
572 313 313/572 Wellness 60 A 0 0 wellness 313 none
573 313 313/573 Men's Grooming 70 A 0 0 mens-grooming 313 none