SELECT 
  f.feature_id, 
  f.purpose, 
  p.product_id, 
  p.parent_product_id, 
  g.id, 
  g.code 
FROM 
  cscart_product_variation_group_features AS f 
  INNER JOIN cscart_product_variation_groups AS g ON f.group_id = g.id 
  INNER JOIN cscart_product_variation_group_products AS p ON f.group_id = p.group_id 
WHERE 
  p.product_id IN (
    8607, 8700, 8725, 8798, 8807, 8271, 8274, 
    8278, 8279, 8285, 8287, 8330, 8333, 
    8374, 8389, 8405, 8430, 8458, 8465, 
    8516, 8518, 8537, 8571, 8582, 8584, 
    8588, 8599, 8726, 8728, 8755, 8756, 
    8803, 8809, 8268, 8331, 8334, 8378, 
    8383, 8436, 8442, 8462, 8539, 8541, 
    8579, 8583, 8606, 8727, 8239, 8270, 
    8286, 8376, 8384, 8401, 8402, 8437, 
    8467, 8468, 8515, 8531, 8533, 8542, 
    8616, 8698, 8707, 8386, 8404, 8449, 
    8522, 8591, 8592, 8598, 8786, 8808
  )

Query time 0.00089

JSON explain

{
  "query_block": {
    "select_id": 1,
    "cost_info": {
      "query_cost": "102.21"
    },
    "nested_loop": [
      {
        "table": {
          "table_name": "p",
          "access_type": "range",
          "possible_keys": [
            "PRIMARY",
            "idx_group_id"
          ],
          "key": "PRIMARY",
          "used_key_parts": [
            "product_id"
          ],
          "key_length": "3",
          "rows_examined_per_scan": 73,
          "rows_produced_per_join": 73,
          "filtered": "100.00",
          "index_condition": "(`softwarepirmam_hewadelivard_cscart_4`.`p`.`product_id` in (8607,8700,8725,8798,8807,8271,8274,8278,8279,8285,8287,8330,8333,8374,8389,8405,8430,8458,8465,8516,8518,8537,8571,8582,8584,8588,8599,8726,8728,8755,8756,8803,8809,8268,8331,8334,8378,8383,8436,8442,8462,8539,8541,8579,8583,8606,8727,8239,8270,8286,8376,8384,8401,8402,8437,8467,8468,8515,8531,8533,8542,8616,8698,8707,8386,8404,8449,8522,8591,8592,8598,8786,8808))",
          "cost_info": {
            "read_cost": "43.81",
            "eval_cost": "7.30",
            "prefix_cost": "51.11",
            "data_read_per_join": "1K"
          },
          "used_columns": [
            "product_id",
            "parent_product_id",
            "group_id"
          ]
        }
      },
      {
        "table": {
          "table_name": "g",
          "access_type": "eq_ref",
          "possible_keys": [
            "PRIMARY"
          ],
          "key": "PRIMARY",
          "used_key_parts": [
            "id"
          ],
          "key_length": "3",
          "ref": [
            "softwarepirmam_hewadelivard_cscart_4.p.group_id"
          ],
          "rows_examined_per_scan": 1,
          "rows_produced_per_join": 73,
          "filtered": "100.00",
          "cost_info": {
            "read_cost": "18.25",
            "eval_cost": "7.30",
            "prefix_cost": "76.66",
            "data_read_per_join": "28K"
          },
          "used_columns": [
            "id",
            "code"
          ]
        }
      },
      {
        "table": {
          "table_name": "f",
          "access_type": "ref",
          "possible_keys": [
            "idx_group_id"
          ],
          "key": "idx_group_id",
          "used_key_parts": [
            "group_id"
          ],
          "key_length": "3",
          "ref": [
            "softwarepirmam_hewadelivard_cscart_4.p.group_id"
          ],
          "rows_examined_per_scan": 1,
          "rows_produced_per_join": 73,
          "filtered": "100.00",
          "cost_info": {
            "read_cost": "18.25",
            "eval_cost": "7.30",
            "prefix_cost": "102.21",
            "data_read_per_join": "7K"
          },
          "used_columns": [
            "feature_id",
            "purpose",
            "group_id"
          ]
        }
      }
    ]
  }
}