SELECT 
  SQL_CALC_FOUND_ROWS products.product_id, 
  products.amount, 
  descr1.product as product, 
  companies.company as company_name, 
  variation_group_products.group_id AS variation_group_id, 
  products.product_type, 
  products.parent_product_id, 
  cscart_product_review_prepared_data.average_rating average_rating, 
  cscart_product_review_prepared_data.reviews_count product_reviews_count 
FROM 
  cscart_products as products 
  LEFT JOIN cscart_product_descriptions as descr1 ON descr1.product_id = products.product_id 
  AND descr1.lang_code = 'en' 
  LEFT JOIN cscart_companies AS companies ON companies.company_id = products.company_id 
  INNER JOIN cscart_products_categories as products_categories ON products_categories.product_id = products.product_id 
  INNER JOIN cscart_categories ON cscart_categories.category_id = products_categories.category_id 
  INNER JOIN cscart_product_variation_group_products AS variation_group_products ON variation_group_products.product_id = products.product_id 
  LEFT JOIN cscart_product_review_prepared_data ON cscart_product_review_prepared_data.product_id = products.product_id 
  AND cscart_product_review_prepared_data.storefront_id = 0 
WHERE 
  1 
  AND companies.status IN ('A') 
  AND (
    products.amount > 0 
    OR products.tracking = 'D'
  ) 
  AND (
    products.usergroup_ids = '' 
    OR FIND_IN_SET(0, products.usergroup_ids) 
    OR FIND_IN_SET(1, products.usergroup_ids)
  ) 
  AND products.status IN ('A') 
  AND variation_group_products.group_id IN (
    13822, 17223, 13853, 16301, 13723, 14719, 
    13157, 14271, 13507, 12288, 12324, 
    15615, 12299
  ) 
GROUP BY 
  products.product_id 
ORDER BY 
  NULL asc

Query time 0.05840

JSON explain

{
  "query_block": {
    "select_id": 1,
    "temporary_table": {
      "nested_loop": [
        {
          "table": {
            "table_name": "variation_group_products",
            "access_type": "range",
            "possible_keys": ["PRIMARY", "idx_group_id"],
            "key": "idx_group_id",
            "key_length": "3",
            "used_key_parts": ["group_id"],
            "rows": 62,
            "filtered": 100,
            "index_condition": "variation_group_products.group_id in (13822,17223,13853,16301,13723,14719,13157,14271,13507,12288,12324,15615,12299)"
          }
        },
        {
          "table": {
            "table_name": "products",
            "access_type": "eq_ref",
            "possible_keys": ["PRIMARY", "status"],
            "key": "PRIMARY",
            "key_length": "3",
            "used_key_parts": ["product_id"],
            "ref": ["dev_db.variation_group_products.product_id"],
            "rows": 1,
            "filtered": 51.89157104,
            "attached_condition": "(products.amount > 0 or products.tracking = 'D') and (products.usergroup_ids = '' or find_in_set(0,products.usergroup_ids) or find_in_set(1,products.usergroup_ids)) and products.`status` = 'A'"
          }
        },
        {
          "table": {
            "table_name": "companies",
            "access_type": "eq_ref",
            "possible_keys": ["PRIMARY"],
            "key": "PRIMARY",
            "key_length": "4",
            "used_key_parts": ["company_id"],
            "ref": ["dev_db.products.company_id"],
            "rows": 1,
            "filtered": 100,
            "attached_condition": "companies.`status` = 'A'"
          }
        },
        {
          "table": {
            "table_name": "descr1",
            "access_type": "eq_ref",
            "possible_keys": ["PRIMARY", "product_id"],
            "key": "PRIMARY",
            "key_length": "11",
            "used_key_parts": ["product_id", "lang_code"],
            "ref": ["dev_db.variation_group_products.product_id", "const"],
            "rows": 1,
            "filtered": 100,
            "attached_condition": "trigcond(descr1.lang_code = 'en')"
          }
        },
        {
          "table": {
            "table_name": "cscart_product_review_prepared_data",
            "access_type": "eq_ref",
            "possible_keys": ["PRIMARY"],
            "key": "PRIMARY",
            "key_length": "7",
            "used_key_parts": ["product_id", "storefront_id"],
            "ref": ["dev_db.variation_group_products.product_id", "const"],
            "rows": 1,
            "filtered": 100
          }
        },
        {
          "table": {
            "table_name": "products_categories",
            "access_type": "ref",
            "possible_keys": ["PRIMARY", "pt"],
            "key": "pt",
            "key_length": "3",
            "used_key_parts": ["product_id"],
            "ref": ["dev_db.variation_group_products.product_id"],
            "rows": 1,
            "filtered": 100
          }
        },
        {
          "table": {
            "table_name": "cscart_categories",
            "access_type": "eq_ref",
            "possible_keys": ["PRIMARY", "p_category_id"],
            "key": "PRIMARY",
            "key_length": "3",
            "used_key_parts": ["category_id"],
            "ref": ["dev_db.products_categories.category_id"],
            "rows": 1,
            "filtered": 100,
            "using_index": true
          }
        }
      ]
    }
  }
}

Result

product_id amount product company_name variation_group_id product_type parent_product_id average_rating product_reviews_count
15451 997 Nourishing Herbal Handmade Soap, Helps Detoxify the Skin, Nourishes Healthy Skin, Antibacterial Properties, Natural Ingredients Lecteur De Craft 12288 V 6197 5.00 2
15450 997 Nourishing Herbal Handmade Soap, Helps Detoxify the Skin, Nourishes Healthy Skin, Antibacterial Properties, Natural Ingredients Lecteur De Craft 12288 V 6197 5.00 2
6197 987 Nourishing Herbal Handmade Soap, Helps Detoxify the Skin, Nourishes Healthy Skin, Antibacterial Properties, Natural Ingredients Lecteur De Craft 12288 P 0 5.00 2
15466 999 Pomelo Essential Oil Vina Samex 12299 V 6085 5.00 4
6085 999 Pomelo Essential Oil Vina Samex 12299 P 0 5.00 4
15613 999 K77 Silk Scarf ÓNG heartmadeinvietnam 12324 P 0 5.00 1
6049 6 K77 Silk Scarf ÓNG heartmadeinvietnam 12324 V 15613 5.00 1
19599 999 Decorative Hand-drawn Wooden Pieces, Customizable Artwork, Cute Decorative Accessories, Minimalist Design, Handmade Product Limart - Zero waste 13157 V 3187 5.00 2
19598 999 Decorative Hand-drawn Wooden Pieces, Customizable Artwork, Cute Decorative Accessories, Minimalist Design, Handmade Product Limart - Zero waste 13157 V 3187 5.00 2
19597 999 Decorative Hand-drawn Wooden Pieces, Customizable Artwork, Cute Decorative Accessories, Minimalist Design, Handmade Product Limart - Zero waste 13157 V 3187 5.00 2
19596 999 Decorative Hand-drawn Wooden Pieces, Customizable Artwork, Cute Decorative Accessories, Minimalist Design, Handmade Product Limart - Zero waste 13157 V 3187 5.00 2
19595 999 Decorative Hand-drawn Wooden Pieces, Customizable Artwork, Cute Decorative Accessories, Minimalist Design, Handmade Product Limart - Zero waste 13157 V 3187 5.00 2
19594 999 Decorative Hand-drawn Wooden Pieces, Customizable Artwork, Cute Decorative Accessories, Minimalist Design, Handmade Product Limart - Zero waste 13157 V 3187 5.00 2
19593 999 Decorative Hand-drawn Wooden Pieces, Customizable Artwork, Cute Decorative Accessories, Minimalist Design, Handmade Product Limart - Zero waste 13157 V 3187 5.00 2
3187 999 Decorative Hand-drawn Wooden Pieces, Customizable Artwork, Cute Decorative Accessories, Minimalist Design, Handmade Product Limart - Zero waste 13157 P 0 5.00 2
21204 999 Premium Natural Soap ADORA 13507 V 21192 5.00 1
21203 999 Premium Natural Soap ADORA 13507 V 21192 5.00 1
21202 999 Premium Natural Soap ADORA 13507 V 21192 5.00 1
21201 999 Premium Natural Soap ADORA 13507 V 21192 5.00 1
21200 999 Premium Natural Soap ADORA 13507 V 21192 5.00 1
21199 999 Premium Natural Soap ADORA 13507 V 21192 5.00 1
21198 999 Premium Natural Soap ADORA 13507 V 21192 5.00 1
21197 999 Premium Natural Soap ADORA 13507 V 21192 5.00 1
21196 999 Premium Natural Soap ADORA 13507 V 21192 5.00 1
21195 999 Premium Natural Soap ADORA 13507 V 21192 5.00 1
21194 999 Premium Natural Soap ADORA 13507 V 21192 5.00 1
21193 999 Premium Natural Soap ADORA 13507 V 21192 5.00 1
21192 999 Premium Natural Soap ADORA 13507 P 0 5.00 1
2345 999 Premium Natural Soap ADORA 13507 V 21192 5.00 1
22302 999 Body Massage Oil Bio LAK 13723 P 0 5.00 2
22729 20 Drawing Engraved Bamboo Ballpoint Pen, Simple and Elegant Design, Hand-Carved Patterns, Eco-Friendly Material drawing engraved bamboo ballpoint pen Nhà An Lành 13822 V 1766 5.00 10
22727 19 Drawing Engraved Bamboo Ballpoint Pen, Simple and Elegant Design, Hand-Carved Patterns, Eco-Friendly Material drawing engraved bamboo ballpoint pen Nhà An Lành 13822 V 1766 5.00 10
22726 20 Drawing Engraved Bamboo Ballpoint Pen, Simple and Elegant Design, Hand-Carved Patterns, Eco-Friendly Material drawing engraved bamboo ballpoint pen Nhà An Lành 13822 V 1766 5.00 10
1766 19 Drawing Engraved Bamboo Ballpoint Pen, Simple and Elegant Design, Hand-Carved Patterns, Eco-Friendly Material drawing engraved bamboo ballpoint pen Nhà An Lành 13822 P 0 5.00 10
22817 998 Face And Body Soap Bar Skinlax 13853 V 1668 5.00 1
22816 998 Face And Body Soap Bar Skinlax 13853 V 1668 5.00 1
22815 998 Face And Body Soap Bar Skinlax 13853 V 1668 5.00 1
22814 998 Face And Body Soap Bar Skinlax 13853 V 1668 5.00 1
22813 998 Face And Body Soap Bar Skinlax 13853 V 1668 5.00 1
22812 998 Face And Body Soap Bar Skinlax 13853 V 1668 5.00 1
22811 998 Face And Body Soap Bar Skinlax 13853 V 1668 5.00 1
22810 998 Face And Body Soap Bar Skinlax 13853 V 1668 5.00 1
22809 998 Face And Body Soap Bar Skinlax 13853 V 1668 5.00 1
1668 998 Face And Body Soap Bar Skinlax 13853 P 0 5.00 1
928 1996 Essential Oil Moisturizing Shower Gel Om Fountain 14271 P 0 5.00 1
24257 1996 Essential Oil Moisturizing Shower Gel Om Fountain 14271 V 928 5.00 1
24258 1996 Essential Oil Moisturizing Shower Gel Om Fountain 14271 V 928 5.00 1
24259 1996 Essential Oil Moisturizing Shower Gel Om Fountain 14271 V 928 5.00 1
26358 1994 Extra Virgin Coconut Oil COCONAM 14719 V 215 5.00 3
215 1998 Extra Virgin Coconut Oil COCONAM 14719 P 0 5.00 3
33715 999 Mallard Round Neck Ao Dai Embroidered Daisy, With Orange Pants Moriko Saigon 15615 P 0 0
33789 999 Mallard Round Neck Ao Dai Embroidered Daisy, With Orange Pants Moriko Saigon 15615 V 33715 0
33790 999 Mallard Round Neck Ao Dai Embroidered Daisy, With Orange Pants Moriko Saigon 15615 V 33715 0
33791 999 Mallard Round Neck Ao Dai Embroidered Daisy, With Orange Pants Moriko Saigon 15615 V 33715 0
6551 999 Passiflora Foetida And Embryo Nelumbinis Instant Tea, Herbal Instant Tea, Vietnamese Herbs, Natural, Healthy, Good For Sleep, Improve Resistance Hygie and Panacee 16301 V 40421 5.00 9
40421 999 Passiflora Foetida And Embryo Nelumbinis Instant Tea, Herbal Instant Tea, Vietnamese Herbs, Natural, Healthy, Good For Sleep, Improve Resistance Hygie and Panacee 16301 P 0 5.00 9
40422 999 Passiflora Foetida And Embryo Nelumbinis Instant Tea, Herbal Instant Tea, Vietnamese Herbs, Natural, Healthy, Good For Sleep, Improve Resistance Hygie and Panacee 16301 V 40421 5.00 9
48986 995 Set of 6 Mantra Kombucha Cans, Kombucha, Fermented Tea, Healthy Drinks, Natural Ingredients, Drinks Good For The Digestive System, Health Gifts Mantra Kombucha 17223 V 48873 5.00 2
48873 995 Set of 6 Mantra Kombucha Cans, Kombucha, Fermented Tea, Healthy Drinks, Natural Ingredients, Drinks Good For The Digestive System, Health Gifts Mantra Kombucha 17223 P 0 5.00 2
48987 995 Set of 6 Mantra Kombucha Cans, Kombucha, Fermented Tea, Healthy Drinks, Natural Ingredients, Drinks Good For The Digestive System, Health Gifts Mantra Kombucha 17223 V 48873 5.00 2
48988 995 Set of 6 Mantra Kombucha Cans, Kombucha, Fermented Tea, Healthy Drinks, Natural Ingredients, Drinks Good For The Digestive System, Health Gifts Mantra Kombucha 17223 V 48873 5.00 2
48989 995 Set of 6 Mantra Kombucha Cans, Kombucha, Fermented Tea, Healthy Drinks, Natural Ingredients, Drinks Good For The Digestive System, Health Gifts Mantra Kombucha 17223 V 48873 5.00 2
48990 994 Set of 6 Mantra Kombucha Cans, Kombucha, Fermented Tea, Healthy Drinks, Natural Ingredients, Drinks Good For The Digestive System, Health Gifts Mantra Kombucha 17223 V 48873 5.00 2
48991 995 Set of 6 Mantra Kombucha Cans, Kombucha, Fermented Tea, Healthy Drinks, Natural Ingredients, Drinks Good For The Digestive System, Health Gifts Mantra Kombucha 17223 V 48873 5.00 2