SELECT 
  b.variant_name, 
  a.* 
FROM 
  cscart_product_option_variants AS a 
  LEFT JOIN cscart_product_option_variants_descriptions AS b ON b.variant_id = a.variant_id 
  AND b.lang_code = 'vi' 
WHERE 
  1 
  AND a.option_id IN (
    1566, 1580, 1397, 1399, 1398, 1506, 1449, 
    1295, 215, 1249, 1199, 1504, 1388, 1270, 
    1156, 1393, 1155
  ) 
  AND a.status = 'A' 
ORDER BY 
  a.position, 
  a.variant_id

Query time 0.00855

JSON explain

{
  "query_block": {
    "select_id": 1,
    "nested_loop": [
      {
        "read_sorted_file": {
          "filesort": {
            "sort_key": "a.position, a.variant_id",
            "table": {
              "table_name": "a",
              "access_type": "range",
              "possible_keys": ["status", "option_id", "option_id_2"],
              "key": "option_id",
              "key_length": "6",
              "used_key_parts": ["option_id", "status"],
              "rows": 47,
              "filtered": 100,
              "index_condition": "a.option_id in (1566,1580,1397,1399,1398,1506,1449,1295,215,1249,1199,1504,1388,1270,1156,1393,1155) and a.`status` = 'A'"
            }
          }
        }
      },
      {
        "table": {
          "table_name": "b",
          "access_type": "eq_ref",
          "possible_keys": ["PRIMARY"],
          "key": "PRIMARY",
          "key_length": "9",
          "used_key_parts": ["variant_id", "lang_code"],
          "ref": ["dev_db.a.variant_id", "const"],
          "rows": 1,
          "filtered": 100,
          "attached_condition": "trigcond(b.lang_code = 'vi')"
        }
      }
    ]
  }
}

Result

variant_name variant_id option_id position modifier modifier_type weight_modifier weight_modifier_type point_modifier point_modifier_type status
Gói quà với hộp giấy cứng 260 215 0 0.000 A 0.000 A 0.000 A A
2957 1199 0 0.000 A 0.000 A 0.000 A A
3475 1295 0 0.000 A 0.000 A 0.000 A A
3745 1398 0 0.000 A 0.000 A 0.000 A A
3747 1399 0 0.000 A 0.000 A 0.000 A A
Viết thiệp 3840 1449 0 0.000 A 0.000 A 0.000 A A
Hộp quà ghi tên (MIỄN PHÍ) 3948 1506 0 0.000 A 0.000 A 0.000 A A
4066 1566 0 0.000 A 0.000 A 0.000 A A
Giấy craft hoa khô 4105 1580 0 49000.000 A 0.000 A 0.000 A A
Giấy craft tag vải 4106 1580 0 79000.000 A 0.000 A 0.000 A A
Nâu 2805 1155 1 0.000 A 0.000 A 0.000 A A
Nâu 2807 1156 1 0.000 A 0.000 A 0.000 A A
2956 1199 1 250000.000 A 0.000 A 0.000 A A
Charm bạc tròn trắng chữ 3233 1249 1 200000.000 A 0.000 A 0.000 A A
Trắng 3351 1270 1 0.000 A 0.000 A 0.000 A A
3474 1295 1 50000.000 A 0.000 A 0.000 A A
Chữ ký 3712 1388 1 0.000 A 0.000 A 0.000 A A
Chữ ký 3725 1393 1 0.000 A 0.000 A 0.000 A A
Chữ ký 3739 1397 1 0.000 A 0.000 A 0.000 A A
3744 1398 1 40000.000 A 0.000 A 0.000 A A
3746 1399 1 0.000 A 0.000 A 0.000 A A
Thêu 2 từ (giá gốc 50K, NAY MIỄN PHÍ) 3941 1504 1 0.000 A 0.000 A 0.000 A A
4065 1566 1 0.000 A 0.000 A 0.000 A A
Đen 2806 1155 2 0.000 A 0.000 A 0.000 A A
Đỏ 2808 1156 2 0.000 A 0.000 A 0.000 A A
Charm bạc Phật trắng 3234 1249 2 400000.000 A 0.000 A 0.000 A A
Đen 3352 1270 2 0.000 A 0.000 A 0.000 A A
In hoa nét mảnh 3713 1388 2 0.000 A 0.000 A 0.000 A A
In hoa nét mảnh 3726 1393 2 0.000 A 0.000 A 0.000 A A
In hoa nét mảnh 3740 1397 2 0.000 A 0.000 A 0.000 A A
Thêu 3 - 4 từ (giá gốc 100K, NAY CHỈ 40K) 3942 1504 2 40000.000 A 0.000 A 0.000 A A
Charm bạc Phật vàng 3235 1249 3 400000.000 A 0.000 A 0.000 A A
Xanh đen 3353 1270 3 0.000 A 0.000 A 0.000 A A
In hoa nét đậm 3714 1388 3 0.000 A 0.000 A 0.000 A A
In hoa nét đậm 3727 1393 3 0.000 A 0.000 A 0.000 A A
In hoa nét đậm 3741 1397 3 0.000 A 0.000 A 0.000 A A
Charm bạc tròn xanh đỏ 3236 1249 4 200000.000 A 0.000 A 0.000 A A
Hồng 3354 1270 4 0.000 A 0.000 A 0.000 A A
Viết tay 3715 1388 4 0.000 A 0.000 A 0.000 A A
Viết tay 3728 1393 4 0.000 A 0.000 A 0.000 A A
Viết tay 3742 1397 4 0.000 A 0.000 A 0.000 A A
Charm bạc bàn tay 3237 1249 5 200000.000 A 0.000 A 0.000 A A
Xám 3355 1270 5 0.000 A 0.000 A 0.000 A A
Viết thường 3716 1388 5 0.000 A 0.000 A 0.000 A A
Viết thường 3729 1393 5 0.000 A 0.000 A 0.000 A A
Viết thường 3743 1397 5 0.000 A 0.000 A 0.000 A A
Không thêm charm 3238 1249 6 0.000 A 0.000 A 0.000 A A