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 (
    17197, 17041, 17200, 17199, 17233, 16733, 
    17038, 17198, 17203, 16309, 17201, 
    12220, 17281, 17249, 17186, 17202
  )

Query time 0.00313

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": 84,
          "filtered": 100,
          "index_condition": "gp.group_id in (17197,17041,17200,17199,17233,16733,17038,17198,17203,16309,17201,12220,17281,17249,17186,17202)"
        }
      },
      {
        "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
19692 15021 68481 12220
19692 15020 68480 12220
19692 15019 68479 12220
24093 40531 83944 16309
24093 40561 83945 16309
24496 44570 85457 16733
24496 44578 85458 16733
24789 47407 86486 17038
24789 47406 86485 17038
24789 47390 86484 17038
24792 47411 86493 17041
24792 47393 86492 17041
24931 48669 86928 17186
24931 48673 86929 17186
24942 48685 86970 17197
24942 48725 86971 17197
24942 48726 86972 17197
24942 48727 86973 17197
24943 48686 86974 17198
24943 48728 86975 17198
24943 48729 86976 17198
24943 48730 86977 17198
24944 48687 86978 17199
24944 48731 86979 17199
24944 48732 86980 17199
24944 48733 86981 17199
24945 48688 86982 17200
24945 48734 86983 17200
24945 48735 86984 17200
24945 48736 86985 17200
24946 48689 86986 17201
24946 48737 86987 17201
24946 48738 86988 17201
24946 48739 86989 17201
24947 48690 86990 17202
24947 48740 86991 17202
24947 48741 86992 17202
24947 48742 86993 17202
24948 48691 86994 17203
24948 48743 86995 17203
24948 48744 86996 17203
24948 48745 86997 17203
24991 49316 87173 17233
24991 49317 87174 17233
24991 49315 87172 17233
24991 49017 87170 17233
24991 49321 87261 17233
24991 49320 87260 17233
24991 49319 87259 17233
24991 49318 87258 17233
24991 49314 87171 17233
25006 49219 87221 17249
25006 49220 87222 17249
25006 49221 87223 17249
25034 49583 87331 17281
25034 49584 87330 17281
25034 49585 87332 17281
25034 49587 87334 17281
25034 49586 87333 17281