SELECT 
  pfv.feature_id, 
  pfv.product_id, 
  pfv.variant_id, 
  gp.group_id 
FROM 
  cscart_product_features_values AS pfv 
  INNER JOIN cscart_product_variation_group_products AS gp ON pfv.product_id = gp.product_id 
  INNER JOIN cscart_product_variation_group_features AS gpf ON gpf.group_id = gp.group_id 
  AND gpf.feature_id = pfv.feature_id 
WHERE 
  pfv.lang_code = 'vi' 
  AND gp.group_id IN (
    13744, 17345, 15672, 17081, 13747, 17242, 
    17210, 13746, 13951, 17080, 17317, 
    12247, 17082, 12833, 15804, 16573, 
    14215, 12575
  )

Query time 0.00530

JSON explain

{
  "query_block": {
    "select_id": 1,
    "nested_loop": [
      {
        "table": {
          "table_name": "gp",
          "access_type": "range",
          "possible_keys": ["PRIMARY", "idx_group_id"],
          "key": "idx_group_id",
          "key_length": "3",
          "used_key_parts": ["group_id"],
          "rows": 111,
          "filtered": 100,
          "index_condition": "gp.group_id in (13744,17345,15672,17081,13747,17242,17210,13746,13951,17080,17317,12247,17082,12833,15804,16573,14215,12575)"
        }
      },
      {
        "table": {
          "table_name": "gpf",
          "access_type": "ref",
          "possible_keys": ["PRIMARY", "idx_group_id"],
          "key": "idx_group_id",
          "key_length": "3",
          "used_key_parts": ["group_id"],
          "ref": ["dev_db.gp.group_id"],
          "rows": 1,
          "filtered": 100
        }
      },
      {
        "table": {
          "table_name": "pfv",
          "access_type": "ref",
          "possible_keys": [
            "PRIMARY",
            "fl",
            "lang_code",
            "product_id",
            "fpl",
            "idx_product_feature_variant_id"
          ],
          "key": "idx_product_feature_variant_id",
          "key_length": "12",
          "used_key_parts": ["product_id", "feature_id", "lang_code"],
          "ref": ["dev_db.gp.product_id", "dev_db.gpf.feature_id", "const"],
          "rows": 1,
          "filtered": 100,
          "attached_condition": "pfv.lang_code = 'vi'",
          "using_index": true
        }
      }
    ]
  }
}

Result

feature_id product_id variant_id group_id
19725 15226 68602 12247
19725 6357 68603 12247
20084 17273 70249 12575
20084 17272 70248 12575
20084 17271 70247 12575
20084 17270 70246 12575
20084 17269 70245 12575
20084 17268 70244 12575
20084 17267 70243 12575
20084 17266 70242 12575
20084 17265 70241 12575
20084 5294 70250 12575
20381 18610 71341 12833
20381 18609 71340 12833
20381 18608 71339 12833
20381 18607 71338 12833
20381 18606 71337 12833
20381 18605 71336 12833
20381 18604 71335 12833
20381 18603 71334 12833
20381 18602 71333 12833
20381 18601 71332 12833
20381 18600 71331 12833
20381 4113 71342 12833
21384 22401 74799 13744
21384 1896 74800 13744
21386 22403 74803 13746
21386 1894 74804 13746
21387 22404 74805 13747
21387 1893 74806 13747
21623 1486 75628 13951
21623 23152 75622 13951
21623 23153 75623 13951
21623 23154 75624 13951
21623 23155 75625 13951
21623 23156 75626 13951
21623 23157 75627 13951
21914 24117 76705 14215
21914 24116 76704 14215
21914 24115 76703 14215
21914 1057 76706 14215
23540 35194 81689 15672
23540 35256 81690 15672
23540 35257 81691 15672
23686 42255 84725 15804
23686 42254 84724 15804
23686 40319 83867 15804
23686 6572 82132 15804
23686 36264 82134 15804
23686 36263 82133 15804
23686 36265 82135 15804
23686 37256 82657 15804
23686 37257 82658 15804
23686 37258 82659 15804
23686 37259 82660 15804
23686 37260 82661 15804
23686 42253 83868 15804
23686 42294 82658 16573
23686 42293 82657 16573
23686 42292 82135 16573
23686 42290 82132 16573
23686 42289 84725 16573
23686 42288 84724 16573
23686 42287 83868 16573
23686 42291 82134 16573
23686 40350 82133 16573
23686 42286 83867 16573
23686 42295 82659 16573
23686 42296 82660 16573
23686 42297 82661 16573
24830 47595 86590 17080
24830 47631 86591 17080
24831 47596 86592 17081
24831 47632 86593 17081
24832 47597 86594 17082
24832 47633 86595 17082
24957 48823 87021 17210
24957 48824 87022 17210
24957 48825 87023 17210
24997 46690 87190 17242
24997 49169 87191 17242
24997 49170 87192 17242
24144 49868 84155 17317
25095 49868 87604 17317
24144 49867 84155 17317
25095 49867 87603 17317
24144 49864 84152 17317
25095 49864 87604 17317
24144 49865 84154 17317
25095 49865 87603 17317
24144 49866 84154 17317
25095 49866 87604 17317
24144 49873 87602 17317
25095 49873 87603 17317
24144 49872 87601 17317
25095 49872 87604 17317
24144 49871 87601 17317
25095 49871 87603 17317
24144 49870 84156 17317
25095 49870 87604 17317
24144 49869 84156 17317
25095 49869 87603 17317
24144 40818 84152 17317
25095 40818 87603 17317
24144 49874 87602 17317
25095 49874 87604 17317
24144 49875 84153 17317
25095 49875 87603 17317
24144 49876 84153 17317
25095 49876 87604 17317
25127 50229 87711 17345
25127 50216 87712 17345
25127 50230 87713 17345