SELECT 
  v.product_id, 
  v.feature_id, 
  v.value, 
  v.value_int, 
  v.variant_id, 
  f.feature_type, 
  fd.description, 
  fd.prefix, 
  fd.suffix, 
  vd.variant, 
  f.parent_id, 
  f.position, 
  gf.position as gposition 
FROM 
  cscart_product_features as f 
  LEFT JOIN cscart_product_features_values as v ON v.feature_id = f.feature_id 
  LEFT JOIN cscart_product_features_descriptions as fd ON fd.feature_id = v.feature_id 
  AND fd.lang_code = 'en' 
  LEFT JOIN cscart_product_feature_variants fv ON fv.variant_id = v.variant_id 
  LEFT JOIN cscart_product_feature_variant_descriptions as vd ON vd.variant_id = fv.variant_id 
  AND vd.lang_code = 'en' 
  LEFT JOIN cscart_product_features as gf ON gf.feature_id = f.parent_id 
  AND gf.feature_type = 'G' 
WHERE 
  f.status IN ('A') 
  AND v.product_id in (
    8509, 8507, 8508, 6447, 6373, 6440, 8714, 
    8713, 8720, 8718, 8719, 8715, 6590, 
    8722, 6336, 8494, 8506, 6444, 8721
  ) 
  AND f.display_on_catalog = 'Y' 
  AND (
    f.categories_path = '' 
    OR FIND_IN_SET(166, f.categories_path) 
    OR FIND_IN_SET(174, f.categories_path) 
    OR FIND_IN_SET(190, f.categories_path) 
    OR FIND_IN_SET(372, f.categories_path) 
    OR FIND_IN_SET(453, f.categories_path) 
    OR FIND_IN_SET(454, f.categories_path)
  ) 
  AND IF(
    f.parent_id, 
    (
      SELECT 
        status 
      FROM 
        cscart_product_features as df 
      WHERE 
        df.feature_id = f.parent_id
    ), 
    'A'
  ) IN ('A') 
  AND (
    v.variant_id != 0 
    OR (
      f.feature_type != 'C' 
      AND v.value != ''
    ) 
    OR (f.feature_type = 'C') 
    OR v.value_int != ''
  ) 
  AND v.lang_code = 'en' 
ORDER BY 
  fd.description, 
  fv.position

Query time 0.00589

JSON explain

{
  "query_block": {
    "select_id": 1,
    "cost_info": {
      "query_cost": "276.77"
    },
    "ordering_operation": {
      "using_temporary_table": true,
      "using_filesort": true,
      "nested_loop": [
        {
          "table": {
            "table_name": "v",
            "access_type": "range",
            "possible_keys": [
              "PRIMARY",
              "fl",
              "variant_id",
              "lang_code",
              "product_id",
              "fpl",
              "idx_product_feature_variant_id"
            ],
            "key": "product_id",
            "used_key_parts": [
              "product_id"
            ],
            "key_length": "3",
            "rows_examined_per_scan": 448,
            "rows_produced_per_join": 145,
            "filtered": "32.52",
            "index_condition": "(`softwarepirmam_hewadelivard_cscart_4`.`v`.`product_id` in (8509,8507,8508,6447,6373,6440,8714,8713,8720,8718,8719,8715,6590,8722,6336,8494,8506,6444,8721))",
            "cost_info": {
              "read_cost": "191.79",
              "eval_cost": "14.57",
              "prefix_cost": "206.36",
              "data_read_per_join": "112K"
            },
            "used_columns": [
              "feature_id",
              "product_id",
              "variant_id",
              "value",
              "value_int",
              "lang_code"
            ],
            "attached_condition": "((`softwarepirmam_hewadelivard_cscart_4`.`v`.`lang_code` = 'en') and (`softwarepirmam_hewadelivard_cscart_4`.`v`.`feature_id` is not null))"
          }
        },
        {
          "table": {
            "table_name": "f",
            "access_type": "eq_ref",
            "possible_keys": [
              "PRIMARY",
              "status"
            ],
            "key": "PRIMARY",
            "used_key_parts": [
              "feature_id"
            ],
            "key_length": "3",
            "ref": [
              "softwarepirmam_hewadelivard_cscart_4.v.feature_id"
            ],
            "rows_examined_per_scan": 1,
            "rows_produced_per_join": 13,
            "filtered": "9.53",
            "cost_info": {
              "read_cost": "36.42",
              "eval_cost": "1.39",
              "prefix_cost": "257.34",
              "data_read_per_join": "5K"
            },
            "used_columns": [
              "feature_id",
              "feature_type",
              "categories_path",
              "parent_id",
              "display_on_catalog",
              "status",
              "position"
            ],
            "attached_condition": "((`softwarepirmam_hewadelivard_cscart_4`.`f`.`status` = 'A') and (`softwarepirmam_hewadelivard_cscart_4`.`f`.`display_on_catalog` = 'Y') and ((`softwarepirmam_hewadelivard_cscart_4`.`f`.`categories_path` = '') or (0 <> find_in_set(166,`softwarepirmam_hewadelivard_cscart_4`.`f`.`categories_path`)) or (0 <> find_in_set(174,`softwarepirmam_hewadelivard_cscart_4`.`f`.`categories_path`)) or (0 <> find_in_set(190,`softwarepirmam_hewadelivard_cscart_4`.`f`.`categories_path`)) or (0 <> find_in_set(372,`softwarepirmam_hewadelivard_cscart_4`.`f`.`categories_path`)) or (0 <> find_in_set(453,`softwarepirmam_hewadelivard_cscart_4`.`f`.`categories_path`)) or (0 <> find_in_set(454,`softwarepirmam_hewadelivard_cscart_4`.`f`.`categories_path`))) and (if(`softwarepirmam_hewadelivard_cscart_4`.`f`.`parent_id`,(/* select#2 */ select `softwarepirmam_hewadelivard_cscart_4`.`df`.`status` from `softwarepirmam_hewadelivard_cscart_4`.`cscart_product_features` `df` where (`softwarepirmam_hewadelivard_cscart_4`.`df`.`feature_id` = `softwarepirmam_hewadelivard_cscart_4`.`f`.`parent_id`)),'A') = 'A') and ((`softwarepirmam_hewadelivard_cscart_4`.`v`.`variant_id` <> 0) or ((`softwarepirmam_hewadelivard_cscart_4`.`f`.`feature_type` <> 'C') and (`softwarepirmam_hewadelivard_cscart_4`.`v`.`value` <> '')) or (`softwarepirmam_hewadelivard_cscart_4`.`f`.`feature_type` = 'C') or (`softwarepirmam_hewadelivard_cscart_4`.`v`.`value_int` <> 0)))",
            "attached_subqueries": [
              {
                "dependent": true,
                "cacheable": false,
                "query_block": {
                  "select_id": 2,
                  "cost_info": {
                    "query_cost": "0.35"
                  },
                  "table": {
                    "table_name": "df",
                    "access_type": "eq_ref",
                    "possible_keys": [
                      "PRIMARY"
                    ],
                    "key": "PRIMARY",
                    "used_key_parts": [
                      "feature_id"
                    ],
                    "key_length": "3",
                    "ref": [
                      "softwarepirmam_hewadelivard_cscart_4.f.parent_id"
                    ],
                    "rows_examined_per_scan": 1,
                    "rows_produced_per_join": 1,
                    "filtered": "100.00",
                    "cost_info": {
                      "read_cost": "0.25",
                      "eval_cost": "0.10",
                      "prefix_cost": "0.35",
                      "data_read_per_join": "440"
                    },
                    "used_columns": [
                      "feature_id",
                      "status"
                    ]
                  }
                }
              }
            ]
          }
        },
        {
          "table": {
            "table_name": "fd",
            "access_type": "eq_ref",
            "possible_keys": [
              "PRIMARY"
            ],
            "key": "PRIMARY",
            "used_key_parts": [
              "feature_id",
              "lang_code"
            ],
            "key_length": "9",
            "ref": [
              "softwarepirmam_hewadelivard_cscart_4.v.feature_id",
              "const"
            ],
            "rows_examined_per_scan": 1,
            "rows_produced_per_join": 13,
            "filtered": "100.00",
            "cost_info": {
              "read_cost": "3.47",
              "eval_cost": "1.39",
              "prefix_cost": "262.20",
              "data_read_per_join": "31K"
            },
            "used_columns": [
              "feature_id",
              "description",
              "prefix",
              "suffix",
              "lang_code"
            ]
          }
        },
        {
          "table": {
            "table_name": "fv",
            "access_type": "eq_ref",
            "possible_keys": [
              "PRIMARY"
            ],
            "key": "PRIMARY",
            "used_key_parts": [
              "variant_id"
            ],
            "key_length": "3",
            "ref": [
              "softwarepirmam_hewadelivard_cscart_4.v.variant_id"
            ],
            "rows_examined_per_scan": 1,
            "rows_produced_per_join": 13,
            "filtered": "100.00",
            "cost_info": {
              "read_cost": "3.47",
              "eval_cost": "1.39",
              "prefix_cost": "267.06",
              "data_read_per_join": "15K"
            },
            "used_columns": [
              "variant_id",
              "position"
            ]
          }
        },
        {
          "table": {
            "table_name": "vd",
            "access_type": "eq_ref",
            "possible_keys": [
              "PRIMARY"
            ],
            "key": "PRIMARY",
            "used_key_parts": [
              "variant_id",
              "lang_code"
            ],
            "key_length": "9",
            "ref": [
              "softwarepirmam_hewadelivard_cscart_4.fv.variant_id",
              "const"
            ],
            "rows_examined_per_scan": 1,
            "rows_produced_per_join": 13,
            "filtered": "100.00",
            "cost_info": {
              "read_cost": "3.47",
              "eval_cost": "1.39",
              "prefix_cost": "271.92",
              "data_read_per_join": "41K"
            },
            "used_columns": [
              "variant_id",
              "variant",
              "lang_code"
            ]
          }
        },
        {
          "table": {
            "table_name": "gf",
            "access_type": "eq_ref",
            "possible_keys": [
              "PRIMARY"
            ],
            "key": "PRIMARY",
            "used_key_parts": [
              "feature_id"
            ],
            "key_length": "3",
            "ref": [
              "softwarepirmam_hewadelivard_cscart_4.f.parent_id"
            ],
            "rows_examined_per_scan": 1,
            "rows_produced_per_join": 13,
            "filtered": "100.00",
            "cost_info": {
              "read_cost": "3.47",
              "eval_cost": "1.39",
              "prefix_cost": "276.77",
              "data_read_per_join": "5K"
            },
            "used_columns": [
              "feature_id",
              "feature_type",
              "position"
            ],
            "attached_condition": "<if>(is_not_null_compl(gf), (`softwarepirmam_hewadelivard_cscart_4`.`gf`.`feature_type` = 'G'), true)"
          }
        }
      ]
    }
  }
}

Result

product_id feature_id value value_int variant_id feature_type description prefix suffix variant parent_id position gposition
6336 641 1647 S Aspect Ratio 16:9 0 30
6373 641 1647 S Aspect Ratio 16:9 0 30
6440 641 1647 S Aspect Ratio 16:9 0 30
6447 641 1647 S Aspect Ratio 16:9 0 30
6590 641 1647 S Aspect Ratio 16:9 0 30
8494 641 1647 S Aspect Ratio 16:9 0 30
8506 641 1647 S Aspect Ratio 16:9 0 30
8507 641 1647 S Aspect Ratio 16:9 0 30
8508 641 1647 S Aspect Ratio 16:9 0 30
8509 641 1647 S Aspect Ratio 16:9 0 30
8713 641 1647 S Aspect Ratio 16:9 0 30
8714 641 1647 S Aspect Ratio 16:9 0 30
8715 641 1647 S Aspect Ratio 16:9 0 30
8718 641 1647 S Aspect Ratio 16:9 0 30
8719 641 1647 S Aspect Ratio 16:9 0 30
8720 641 1647 S Aspect Ratio 16:9 0 30
6336 657 6214 E Brand TCL 0 0
6373 657 6214 E Brand TCL 0 0
6440 657 6214 E Brand TCL 0 0
6444 657 6214 E Brand TCL 0 0
6447 657 6214 E Brand TCL 0 0
6590 657 8274 E Brand Toshiba 0 0
8494 657 8274 E Brand Toshiba 0 0
8506 657 6214 E Brand TCL 0 0
8507 657 6214 E Brand TCL 0 0
8508 657 6214 E Brand TCL 0 0
8509 657 6214 E Brand TCL 0 0
8713 657 6214 E Brand TCL 0 0
8714 657 6214 E Brand TCL 0 0
8715 657 6214 E Brand TCL 0 0
8718 657 6214 E Brand TCL 0 0
8719 657 6214 E Brand TCL 0 0
8720 657 6214 E Brand TCL 0 0
8721 657 6214 E Brand TCL 0 0
8722 657 6214 E Brand TCL 0 0
6336 656 1560 S Color Black 0 160
6373 656 1560 S Color Black 0 160
6440 656 1560 S Color Black 0 160
6447 656 1560 S Color Black 0 160
6590 656 1560 S Color Black 0 160
8494 656 1560 S Color Black 0 160
8506 656 1560 S Color Black 0 160
8507 656 1560 S Color Black 0 160
8508 656 1560 S Color Black 0 160
8509 656 1560 S Color Black 0 160
8713 656 1560 S Color Black 0 160
8714 656 1560 S Color Black 0 160
8715 656 1560 S Color Black 0 160
8718 656 1560 S Color Black 0 160
8719 656 1560 S Color Black 0 160
8720 656 1560 S Color Black 0 160
6336 640 2584 S Operating System Google TV 0 10
6373 640 2584 S Operating System Google TV 0 10
6440 640 2584 S Operating System Google TV 0 10
6447 640 2584 S Operating System Google TV 0 10
6590 640 8287 S Operating System VIDAA 0 10
8494 640 8287 S Operating System VIDAA 0 10
8506 640 2584 S Operating System Google TV 0 10
8507 640 2584 S Operating System Google TV 0 10
8508 640 2584 S Operating System Google TV 0 10
8509 640 2584 S Operating System Google TV 0 10
8713 640 2584 S Operating System Google TV 0 10
8714 640 2584 S Operating System Google TV 0 10
8715 640 2584 S Operating System Google TV 0 10
8718 640 2584 S Operating System Google TV 0 10
8719 640 2584 S Operating System Google TV 0 10
8720 640 2584 S Operating System Google TV 0 10
6336 645 8135 S Ports 3 × HDMI, 1 × USB, Ethernet, Wi-Fi, Bluetooth 5.0 0 110
6373 645 8171 S Ports HDMI, USB, Ethernet, Optical, AV In 0 110
6440 645 8254 S Ports HDMI, USB, Ethernet, Optical, Audio Out 0 110
6447 645 8254 S Ports HDMI, USB, Ethernet, Optical, Audio Out 0 110
6590 645 8290 S Ports 4x HDMI, 2x USB, Ethernet, Wi-Fi 0 110
8494 645 8290 S Ports 4x HDMI, 2x USB, Ethernet, Wi-Fi 0 110
8506 645 8135 S Ports 3 × HDMI, 1 × USB, Ethernet, Wi-Fi, Bluetooth 5.0 0 110
8507 645 8171 S Ports HDMI, USB, Ethernet, Optical, AV In 0 110
8508 645 8171 S Ports HDMI, USB, Ethernet, Optical, AV In 0 110
8509 645 8171 S Ports HDMI, USB, Ethernet, Optical, AV In 0 110
8713 645 8254 S Ports HDMI, USB, Ethernet, Optical, Audio Out 0 110
8714 645 8254 S Ports HDMI, USB, Ethernet, Optical, Audio Out 0 110
8715 645 8254 S Ports HDMI, USB, Ethernet, Optical, Audio Out 0 110
8718 645 8254 S Ports HDMI, USB, Ethernet, Optical, Audio Out 0 110
8719 645 8254 S Ports HDMI, USB, Ethernet, Optical, Audio Out 0 110
8720 645 8254 S Ports HDMI, USB, Ethernet, Optical, Audio Out 0 110
6336 651 6679 S Processor AiPQ Processor 0 60
6373 651 8170 S Processor AiPQ Engine Processor 0 60
6440 651 8253 S Processor AiPQ Engine (TCL proprietary) 0 60
6447 651 8256 S Processor TCL AiPQ Engine 0 60
6590 651 8289 S Processor REGZA ZRi 4K Processor 0 60
8494 651 8289 S Processor REGZA ZRi 4K Processor 0 60
8506 651 6679 S Processor AiPQ Processor 0 60
8507 651 8170 S Processor AiPQ Engine Processor 0 60
8508 651 8170 S Processor AiPQ Engine Processor 0 60
8509 651 8170 S Processor AiPQ Engine Processor 0 60
8713 651 8256 S Processor TCL AiPQ Engine 0 60
8714 651 8256 S Processor TCL AiPQ Engine 0 60
8715 651 8256 S Processor TCL AiPQ Engine 0 60
8718 651 8253 S Processor AiPQ Engine (TCL proprietary) 0 60
8719 651 8253 S Processor AiPQ Engine (TCL proprietary) 0 60
8720 651 8253 S Processor AiPQ Engine (TCL proprietary) 0 60
6336 650 1539 S Refresh Rate 60Hz 0 40
6373 650 7542 S Refresh Rate 120 Hz 0 40
6440 650 8251 S Refresh Rate 144Hz (Motion Clarity Pro) 0 40
6447 650 7542 S Refresh Rate 120 Hz 0 40
6590 650 1541 S Refresh Rate 144Hz 0 40
8494 650 1541 S Refresh Rate 144Hz 0 40
8506 650 1539 S Refresh Rate 60Hz 0 40
8507 650 7542 S Refresh Rate 120 Hz 0 40
8508 650 7542 S Refresh Rate 120 Hz 0 40
8509 650 7542 S Refresh Rate 120 Hz 0 40
8713 650 7542 S Refresh Rate 120 Hz 0 40
8714 650 7542 S Refresh Rate 120 Hz 0 40
8715 650 7542 S Refresh Rate 120 Hz 0 40
8718 650 8251 S Refresh Rate 144Hz (Motion Clarity Pro) 0 40
8719 650 8251 S Refresh Rate 144Hz (Motion Clarity Pro) 0 40
8720 650 8251 S Refresh Rate 144Hz (Motion Clarity Pro) 0 40
6336 642 6280 S Resolution 3840 × 2160 (4K UHD) 0 50
6373 642 8143 S Resolution 4K UHD 0 50
6440 642 8252 S Resolution 3840 x 2160 (4K Ultra HD) 0 50
6447 642 8255 S Resolution 3840 x 2160 pixels 0 50
6590 642 8288 S Resolution 4K Ultra HD (3840 x 2160) 0 50
8494 642 8288 S Resolution 4K Ultra HD (3840 x 2160) 0 50
8506 642 6280 S Resolution 3840 × 2160 (4K UHD) 0 50
8507 642 8143 S Resolution 4K UHD 0 50
8508 642 8143 S Resolution 4K UHD 0 50
8509 642 8143 S Resolution 4K UHD 0 50
8713 642 8255 S Resolution 3840 x 2160 pixels 0 50
8714 642 8255 S Resolution 3840 x 2160 pixels 0 50
8715 642 8255 S Resolution 3840 x 2160 pixels 0 50
8718 642 8252 S Resolution 3840 x 2160 (4K Ultra HD) 0 50
8719 642 8252 S Resolution 3840 x 2160 (4K Ultra HD) 0 50
8720 642 8252 S Resolution 3840 x 2160 (4K Ultra HD) 0 50
8713 766 8560 S TV Display 43" 0 0
8714 766 8551 S TV Display 50" 0 0
6373 766 8557 S TV Display 55" 0 0
8715 766 8557 S TV Display 55" 0 0
8718 766 8557 S TV Display 55" 0 0
8721 766 8557 S TV Display 55" 0 0
6336 766 8558 S TV Display 65" 0 0
6447 766 8558 S TV Display 65" 0 0
8508 766 8558 S TV Display 65" 0 0
8719 766 8558 S TV Display 65" 0 0
8722 766 8558 S TV Display 65" 0 0
6444 766 8553 S TV Display 75" 0 0
8494 766 8553 S TV Display 75" 0 0
8506 766 8553 S TV Display 75" 0 0
8509 766 8553 S TV Display 75" 0 0
8720 766 8553 S TV Display 75" 0 0
6440 766 8556 S TV Display 85" 0 0
6590 766 8556 S TV Display 85" 0 0
8507 766 8556 S TV Display 85" 0 0