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 (
    3415, 3077, 3409, 3411, 2926, 3128, 3035, 
    3043, 3095, 3437, 3412, 3436, 5104, 
    3438, 3860, 3858, 3853, 3857, 3863, 
    3862, 3854, 3855, 3859, 5105, 6062, 
    6060, 6061
  ) 
  AND f.display_on_catalog = 'Y' 
  AND (
    f.categories_path = '' 
    OR FIND_IN_SET(166, f.categories_path) 
    OR FIND_IN_SET(423, f.categories_path) 
    OR FIND_IN_SET(424, f.categories_path) 
    OR FIND_IN_SET(451, 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.00691

JSON explain

{
  "query_block": {
    "select_id": 1,
    "cost_info": {
      "query_cost": "276.95"
    },
    "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": "idx_product_feature_variant_id",
            "used_key_parts": [
              "product_id"
            ],
            "key_length": "3",
            "rows_examined_per_scan": 445,
            "rows_produced_per_join": 144,
            "filtered": "32.52",
            "index_condition": "(((`softwarepirmam_hewadelivard_cscart_4`.`v`.`product_id` in (3415,3077,3409,3411,2926,3128,3035,3043,3095,3437,3412,3436,5104,3438,3860,3858,3853,3857,3863,3862,3854,3855,3859,5105,6062,6060,6061)) and (`softwarepirmam_hewadelivard_cscart_4`.`v`.`lang_code` = 'en')) and (`softwarepirmam_hewadelivard_cscart_4`.`v`.`feature_id` is not null))",
            "cost_info": {
              "read_cost": "192.54",
              "eval_cost": "14.47",
              "prefix_cost": "207.01",
              "data_read_per_join": "111K"
            },
            "used_columns": [
              "feature_id",
              "product_id",
              "variant_id",
              "value",
              "value_int",
              "lang_code"
            ]
          }
        },
        {
          "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.17",
              "eval_cost": "1.38",
              "prefix_cost": "257.65",
              "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(423,`softwarepirmam_hewadelivard_cscart_4`.`f`.`categories_path`)) or (0 <> find_in_set(424,`softwarepirmam_hewadelivard_cscart_4`.`f`.`categories_path`)) or (0 <> find_in_set(451,`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.45",
              "eval_cost": "1.38",
              "prefix_cost": "262.48",
              "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.45",
              "eval_cost": "1.38",
              "prefix_cost": "267.30",
              "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.45",
              "eval_cost": "1.38",
              "prefix_cost": "272.13",
              "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.45",
              "eval_cost": "1.38",
              "prefix_cost": "276.95",
              "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
2926 657 2082 E Brand Anker 0 0
3035 657 2082 E Brand Anker 0 0
3043 657 2082 E Brand Anker 0 0
3077 657 2082 E Brand Anker 0 0
3095 657 2082 E Brand Anker 0 0
3128 657 2082 E Brand Anker 0 0
3409 657 3820 E Brand Dviced 0 0
3411 657 3820 E Brand Dviced 0 0
3412 657 3933 E Brand Belkin 0 0
3415 657 3820 E Brand Dviced 0 0
3436 657 3961 E Brand Baykron 0 0
3437 657 3961 E Brand Baykron 0 0
3438 657 3961 E Brand Baykron 0 0
3853 657 3961 E Brand Baykron 0 0
3854 657 3961 E Brand Baykron 0 0
3855 657 3961 E Brand Baykron 0 0
3857 657 3961 E Brand Baykron 0 0
3858 657 3961 E Brand Baykron 0 0
3859 657 3961 E Brand Baykron 0 0
3860 657 3961 E Brand Baykron 0 0
3862 657 3961 E Brand Baykron 0 0
3863 657 3961 E Brand Baykron 0 0
5104 657 6600 E Brand Philips 0 0
5105 657 6600 E Brand Philips 0 0
6060 657 1665 E Brand Apple 0 0
6061 657 1665 E Brand Apple 0 0
6062 657 1665 E Brand Apple 0 0
3412 709 3927 S Cable Type 2 meter detachable power cable (AC). 0 0
2926 654 4473 S Charging Type Up to 52.5 W total: PD 3.0, PowerIQ 3.0, PPS, ActiveShield 2.0 0 120
3035 654 4547 S Charging Type USB Power Delivery 3.1, PPS, ActiveShield™ 2.0 0 120
3043 654 4503 S Charging Type PD 3.0 on C; PowerIQ on A; combined ~30 W; MultiProtect safety 0 120
3077 654 4484 S Charging Type PD 3.0 20 W, PowerIQ 3.0, ActiveShield™ safety 0 120
3095 654 4498 S Charging Type Quick Charge 3.0 (one port), PowerIQ + VoltageBoost (other); MultiProtect safety 0 120
3128 654 4448 S Charging Type USB‑C Power Delivery (PD 3.0) with PowerIQ 3.0, featuring the ActiveShield™ safety system (dynamic temperature sensor + power tuner chip) 0 120
3409 654 4591 S Charging Type GaN Technology, Power Delivery 3.0 0 120
3411 654 0.00 4598 S Charging Type GaN technology; USB Power Delivery 3.0 + Quick Charge 3.0 0 120
3415 654 4580 S Charging Type GaN Technology, Power Delivery 3.0, Quick Charge 3.0 0 120
3436 654 3968 S Charging Type Ultra Fast Charge (GaN Technology) 0 120
3437 654 3968 S Charging Type Ultra Fast Charge (GaN Technology) 0 120
3438 654 3968 S Charging Type Ultra Fast Charge (GaN Technology) 0 120
3853 654 4768 S Charging Type Plug-in Adapter 0 120
3854 654 4558 S Charging Type USB-C Power Delivery (PD) 0 120
3855 654 4799 S Charging Type Fast Charging, Power Delivery (PD) 3.0, Quick Charge (QC) 3.0 0 120
3857 654 4768 S Charging Type Plug-in Adapter 0 120
3858 654 4558 S Charging Type USB-C Power Delivery (PD) 0 120
3859 654 4799 S Charging Type Fast Charging, Power Delivery (PD) 3.0, Quick Charge (QC) 3.0 0 120
3860 654 0.00 4805 S Charging Type Car Charger 0 120
3862 654 4799 S Charging Type Fast Charging, Power Delivery (PD) 3.0, Quick Charge (QC) 3.0 0 120
3863 654 0.00 4811 S Charging Type Fast Charging, Power Delivery (PD) 3.0, USB 3.0 0 120
5104 654 7113 S Charging Type PD Fast Charging + QC 0 120
5105 654 7113 S Charging Type PD Fast Charging + QC 0 120
2926 656 1560 S Color Black 0 160
3035 656 1560 S Color Black 0 160
3043 656 1560 S Color Black 0 160
3077 656 1560 S Color Black 0 160
3095 656 1560 S Color Black 0 160
3128 656 2985 S Color Aurora Purple 0 160
3409 656 1560 S Color Black 0 160
3411 656 1560 S Color Black 0 160
3412 656 1559 S Color white 0 160
3415 656 1560 S Color Black 0 160
3436 656 1560 S Color Black 0 160
3437 656 1560 S Color Black 0 160
3438 656 1560 S Color Black 0 160
3853 656 1560 S Color Black 0 160
3854 656 1560 S Color Black 0 160
3855 656 1560 S Color Black 0 160
3857 656 1560 S Color Black 0 160
3858 656 1560 S Color Black 0 160
3859 656 1560 S Color Black 0 160
3860 656 1560 S Color Black 0 160
3862 656 1560 S Color Black 0 160
3863 656 1560 S Color Black 0 160
5104 656 1560 S Color Black 0 160
5105 656 1559 S Color white 0 160
6060 656 1559 S Color white 0 160
6061 656 1559 S Color white 0 160
6062 656 1559 S Color white 0 160
2926 683 12.00 4475 S Input 12 V @ 5.6 A or 24 V @ 3.6 A 0 310
3035 683 100.00 4549 S Input 100–240V AC, 3.5A, 50–60Hz 0 310
3043 683 12.00 4505 S Input 12 V or 24 V DC car outlet 0 310
3077 683 4454 S Input 100–240 V AC, ~0.6 A, 50–60 Hz 0 310
3095 683 12.00 4500 S Input 12 V / 24 V car outlet 0 310
3128 683 4445 S Input 100–240 V AC 0 310
3409 683 4588 S Input 100–240V AC, 2.5A, 50/60Hz 0 310
3411 683 100.00 4600 S Input 100–240 V AC, ~1.0 A, 50–60 Hz 0 310
3412 683 3925 S Input AC 100–240V 0 310
3415 683 100.00 4588 S Input 100–240V AC, 2.5A, 50/60Hz 0 310
3436 683 3176 S Input 100-240V AC, 50/60Hz. 0 310
3437 683 3176 S Input 100-240V AC, 50/60Hz. 0 310
3438 683 3176 S Input 100-240V AC, 50/60Hz. 0 310
3853 683 100.00 4797 S Input 100-240V 0 310
3854 683 4797 S Input 100-240V 0 310
3855 683 4797 S Input 100-240V 0 310
3857 683 4797 S Input 100-240V 0 310
3858 683 4797 S Input 100-240V 0 310
3859 683 4797 S Input 100-240V 0 310
3860 683 4812 S Input 12-24V DC 0 310
3862 683 4812 S Input 12-24V DC 0 310
3863 683 12.00 4812 S Input 12-24V DC 0 310
5104 683 7110 S Input AC 100–240V, 50/60Hz 0 310
5105 683 4569 S Input 100–240V AC, 0.6A, 50/60Hz 0 310
2926 658 4474 S Model A2735 0 155
3035 658 4548 S Model A2342 0 155
3043 658 4504 S Model A2741 0 155
3077 658 4449 S Model A2637 0 155
3095 658 4499 S Model A2228 0 155
3128 658 4449 S Model A2637 0 155
3409 658 4592 S Model DV221003 0 155
3411 658 0.00 4599 S Model DV222004 0 155
3415 658 4587 S Model DV222009 0 155
5104 658 0.00 7116 S Model DLP5312NB 0 155
5105 658 0.00 7118 S Model DLP6331CW 0 155
2926 684 0.00 4476 S Output USB‑C up to 30 W; USB‑A up to 22.5 W 0 320
3035 684 0.00 4550 S Output USB-C1: 140W (5V/3A, 9V/3A, 15V/3A, 20V/5A, 28V/5A), USB-C2/C3: 100W shared (5V/3A, 9V/3A, 15V/3A, 20V/5A), USB-A: 22.5W (5V/3A, 9V/2A, 12V/1.5A, 4.5V/5A, 10V/2.25A) 0 320
3043 684 0.00 4506 S Output USB‑C: ~18 W; USB‑A: ~12 W; total ~30 W 0 320
3077 684 5.00 4485 S Output 5 V/3 A or 9 V/2.22 A (max 20 W) 0 320
3095 684 0.00 4501 S Output QC port up to ~18 W; second port adjusts up to total 39 W 0 320
3128 684 4446 S Output 20 W total — 5 V ⎓ 3 A or 9 V ⎓ 2.22 A via USB‑C 0 320
3409 684 0.00 4593 S Output USB-C: 5V/3A, 9V/3A, 12V/2.5A, 15V/2A, 20V/1.5A, USB-A Output: 5V/3A, 9V/2A, 12V/1.5A, Total Output: Up to 30W 0 320
3411 684 0.00 4601 S Output USB-C: Up to 35 W — e.g. 5 V⎓3 A, 9 V⎓3 A, 12 V⎓2.92 A, 15 V⎓2.33 A, 20 V⎓1.75 A, USB-A: Up to 18 W — e.g. 5 V⎓3 A, 9 V⎓2 A, 12 V⎓1.5 A, Total Output: Maximum combined35W 0 320
3412 684 108.00 3928 S Output 108W total across all ports. 0 320
3415 684 0.00 4589 S Output USB-C1: 5V/3A, 9V/3A, 12V/3A, 15V/3A, 20V/5A, 28V/5A, PPS: 3.3–11V/5A, 3.3–21V/3.25A, USB-C2: 5V/3A, 9V/3A, 12V/3A, 15V/3A, 20V/5A, 28V/5A, PPS: 3.3–11V/5A, 3.3–21V/3.25A, USB-A: 5V/3A, 9V/2A, 12V/1.5A, 10V/2.25A, Total Output: Up to 140W 0 320
3436 684 3970 S Output 33W 0 320
3437 684 3971 S Output 65W 0 320
3438 684 3971 S Output 65W 0 320
3853 684 4770 S Output 12W 0 320
3854 684 4798 S Output 20W 0 320
3855 684 36.00 4800 S Output 36W 0 320
3857 684 4770 S Output 12W 0 320
3858 684 4798 S Output 20W 0 320
3859 684 4800 S Output 36W 0 320
3860 684 4770 S Output 12W 0 320
3862 684 4800 S Output 36W 0 320
3863 684 40.00 4813 S Output 40W 0 320
5104 684 7115 S Output 30W (USB-C PD), 18W (USB-A QC) 0 320
5105 684 100.00 7119 S Output 100W (Max, USB-C PD), 30W (USB-A QC) 0 320
2926 645 2914 S Ports 1 x USB-C, 1 x USB-A 0 110
3035 645 2962 S Ports 3 x USB-C, 1 x USB-A 0 110
3043 645 2914 S Ports 1 x USB-C, 1 x USB-A 0 110
3077 645 2900 S Ports 1 x USB-C 0 110
3095 645 3495 S Ports 2 x USB-A 0 110
3128 645 4447 S Ports 1 x USB-C (single port up to 20W) 0 110
3409 645 2914 S Ports 1 x USB-C, 1 x USB-A 0 110
3411 645 2914 S Ports 1 x USB-C, 1 x USB-A 0 110
3412 645 3827 S Ports 2 USB-C ports and 2 USB-A ports. 0 110
3415 645 2909 S Ports 2 x USB-C, 1 x USB-A 0 110
3436 645 2900 S Ports 1 x USB-C 0 110
3437 645 2914 S Ports 1 x USB-C, 1 x USB-A 0 110
3438 645 2914 S Ports 1 x USB-C, 1 x USB-A 0 110
3853 645 3495 S Ports 2 x USB-A 0 110
3854 645 2900 S Ports 1 x USB-C 0 110
3855 645 2914 S Ports 1 x USB-C, 1 x USB-A 0 110
3857 645 3495 S Ports 2 x USB-A 0 110
3859 645 2914 S Ports 1 x USB-C, 1 x USB-A 0 110
3860 645 3495 S Ports 2 x USB-A 0 110
3862 645 2914 S Ports 1 x USB-C, 1 x USB-A 0 110
3863 645 2.00 4810 S Ports 2 x USB-A 3.0, 1 x USB-C 0 110
5104 645 7112 S Ports 2×Ports (1×USB-C, 1×USB-A) 0 110
5105 645 4.00 7117 S Ports 4×Ports (3×USB-C, 1×USB-A) 0 110