SELECT 
  a.variant_id, 
  a.option_id, 
  a.position, 
  a.modifier, 
  a.modifier_type, 
  a.weight_modifier, 
  a.weight_modifier_type, 
  a.nav_skus, 
  a.commercial_modifier, 
  a.commercial_dn, 
  a.same_as_option, 
  a.price_overrides, 
  a.base_cost, 
  b.variant_name, 
  IF(
    shared_option_variants.variant_id IS NOT NULL, 
    shared_option_variants.modifier, 
    a.modifier
  ) as modifier, 
  IF(
    shared_option_variants.variant_id IS NOT NULL, 
    shared_option_variants.modifier_type, 
    a.modifier_type
  ) as modifier_type 
FROM 
  cscart_product_option_variants as a 
  LEFT JOIN cscart_product_option_variants_descriptions as b ON a.variant_id = b.variant_id 
  AND b.lang_code = 'en' 
  LEFT JOIN cscart_ult_product_option_variants shared_option_variants ON shared_option_variants.variant_id = a.variant_id 
  AND shared_option_variants.company_id = 1 
WHERE 
  a.option_id IN (
    22986, 21970, 22987, 22035, 22067, 22040, 
    23587, 23537, 21941
  ) 
  AND a.status = 'A' 
ORDER BY 
  a.position, 
  a.variant_id

Query time 0.00327

JSON explain

{
  "query_block": {
    "select_id": 1,
    "table": {
      "table_name": "shared_option_variants",
      "access_type": "system",
      "possible_keys": ["PRIMARY", "company_id"],
      "rows": 0,
      "filtered": 0,
      "const_row_not_found": true
    },
    "read_sorted_file": {
      "filesort": {
        "sort_key": "a.position, a.variant_id",
        "table": {
          "table_name": "a",
          "access_type": "range",
          "possible_keys": ["option_id", "option_id_2", "status"],
          "key": "option_id",
          "key_length": "6",
          "used_key_parts": ["option_id", "status"],
          "rows": 203,
          "filtered": 100,
          "index_condition": "a.option_id in (22986,21970,22987,22035,22067,22040,23587,23537,21941) 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": ["cscart_migrate.a.variant_id", "const"],
      "rows": 1,
      "filtered": 100,
      "attached_condition": "trigcond(b.lang_code = 'en')"
    }
  }
}

Result

variant_id option_id position modifier modifier_type weight_modifier weight_modifier_type nav_skus commercial_modifier commercial_dn same_as_option price_overrides base_cost variant_name
218476 21970 0 0.000 A 0.000 A unselected 0.00 0.00 0 0.00 Please Select
220181 22035 0 0.000 A 0.000 A skip 0.00 0.00 0 0.00 Please Select
220231 22067 0 0.000 A 0.000 A skip 0.00 0.00 0 0.00 Please Select
220272 22040 0 0.000 A 0.000 A skip 0.00 0.00 0 0.00 Please Select
220318 21941 0 0.000 A 0.000 A skip 0.00 0.00 0 0.00 Please Select
229352 22986 0 0.000 A 0.000 A unselected 0.00 0.00 0 0.00 Please Select
229382 22987 0 0.000 A 0.000 A skip 0.00 0.00 0 0.00 Please Select
236827 23537 0 0.000 A 0.000 A skip 0.00 0.00 0 0.00 Please Select
238137 23587 0 0.000 A 0.000 A skip 0.00 0.00 0 0.00 Please Select
215376 21941 3 0.000 A 0.000 A E26 0.00 0.00 0 0.00 E26
215713 21970 3 0.000 A 0.000 A 100 0.00 0.00 0 0.00 100-Black
217235 22035 3 0.000 A 0.000 A 0.00 0.00 21970 0.00 Same as Shade
217308 22040 3 0.000 A 0.000 A 100 0.00 0.00 0 0.00 100-Black
217630 22067 3 0.000 A 0.000 A NA 0.00 0.00 0 0.00 None
229346 22986 3 0.000 A 0.000 A ULW12 0.00 0.00 0 0.00 12" Shade
229353 22987 3 11.000 A 0.000 A G26 0.00 0.00 0 0.00 G26 Gooseneck Arm
236823 23537 3 0.000 A 0.000 A NA 0.00 0.00 0 0.00 None
238107 23587 3 0.000 A 0.000 A 100 0.00 0.00 0 0.00 100-Black
215377 21941 5 14.000 A 0.000 A GU24 0.00 0.00 0 3.50 GU24
215714 21970 5 0.000 A 0.000 A 105 0.00 0.00 0 0.00 105-Textured Black
217236 22035 5 0.000 A 0.000 A 100 0.00 0.00 0 0.00 100-Black
217309 22040 5 0.000 A 0.000 A 105 0.00 0.00 0 0.00 105-Textured Black
217631 22067 5 87.000 A 0.000 A ACR 0.00 0.00 0 {"229346":"75.00","229347":"85.00","229348":"95.00","229349":"140.00","236650":"165.00"} 0.00 Acrylic Diffuser
229347 22986 5 13.000 A 0.000 A ULW14 0.00 0.00 0 0.00 14" Shade
229354 22987 5 12.000 A 0.000 A G11 0.00 0.00 0 0.00 G11 Gooseneck Arm
236824 23537 5 43.000 A 0.000 A DBPC 0.00 0.00 0 0.00 Decorative BP Cover
238108 23587 5 0.000 A 0.000 A 105 0.00 0.00 0 0.00 105-Textured Black
217264 22035 8 0.000 A 0.000 A 105 0.00 0.00 0 0.00 105-Textured Black
236828 23537 8 61.000 A 0.000 A DCHX 0.00 0.00 0 0.00 Decorative BP & Hex Cover
215715 21970 10 0.000 A 0.000 A 200 0.00 0.00 0 0.00 200-White
217237 22035 10 0.000 A 0.000 A 200 0.00 0.00 0 0.00 200-White
217310 22040 10 0.000 A 0.000 A 200 0.00 0.00 0 0.00 200-White
217632 22067 10 49.000 A 0.000 A WC 0.00 0.00 0 0.00 Wire Cage
229348 22986 10 24.000 A 0.000 A ULW16 0.00 0.00 0 0.00 16" Shade
229355 22987 10 15.000 A 0.000 A G15 0.00 0.00 0 0.00 G15 Gooseneck Arm
236825 23537 10 92.000 A 0.000 A DD 0.00 0.00 0 0.00 Dusk-to-Dawn Photocell
238109 23587 10 0.000 A 0.000 A 200 0.00 0.00 0 0.00 200-White
215716 21970 15 0.000 A 0.000 A 300 0.00 0.00 0 0.00 300-Dark Green
217238 22035 15 0.000 A 0.000 A 300 0.00 0.00 0 0.00 300-Dark Green
217311 22040 15 0.000 A 0.000 A 300 0.00 0.00 0 0.00 300-Dark Green
229349 22986 15 36.000 A 0.000 A ULW18 0.00 0.00 0 0.00 18" Shade
229356 22987 15 17.000 A 0.000 A G22 0.00 0.00 0 0.00 G22 Gooseneck Arm
236826 23537 15 83.000 A 0.000 A HDBP 0.00 0.00 0 0.00 Heavy Duty BP
238110 23587 15 0.000 A 0.000 A 300 0.00 0.00 0 0.00 300-Dark Green
215738 21970 18 0.000 A 0.000 A 975 0.00 0.00 0 0.00 975-Galvanized
229376 22987 18 14.000 A 0.000 A G8 0.00 0.00 0 0.00 G8 Gooseneck Arm
215731 21970 19 0.000 A 0.000 A 605 0.00 0.00 0 0.00 605-Textured Rust
217239 22035 20 0.000 A 0.000 A 975 0.00 0.00 0 0.00 975-Galvanized
217312 22040 20 0.000 A 0.000 A 975 0.00 0.00 0 0.00 975-Galvanized
229357 22987 20 26.000 A 0.000 A G24 0.00 0.00 0 0.00 G24 Gooseneck Arm
236650 22986 20 47.000 A 0.000 A ULW20 0.00 0.00 0 0.00 20" Shade
238111 23587 20 0.000 A 0.000 A 975 0.00 0.00 0 0.00 975-Galvanized
237036 21970 21 18.000 A 0.000 A 106 0.00 0.00 0 0.00 106-Matte Black
237037 21970 22 18.000 A 0.000 A 206 0.00 0.00 0 0.00 206-Matte White
215717 21970 24 18.000 A 0.000 A 307 0.00 0.00 0 0.00 307-Emerald Green
217240 22035 25 0.000 A 0.000 A 980 0.00 0.00 0 0.00 980-Brushed Aluminum
217313 22040 25 0.000 A 0.000 A 605 0.00 0.00 0 0.00 605-Textured Rust
229358 22987 25 26.000 A 0.000 A G6 0.00 0.00 0 0.00 G6 Gooseneck Arm
238112 23587 25 0.000 A 0.000 A 605 0.00 0.00 0 0.00 605-Textured Rust
242135 21970 25 18.000 A 0.000 A 311 0.00 0.00 0 0.00 311-Jadite
241141 21970 26 18.000 A 0.000 A 320 0.00 0.00 0 0.00 320-Fern Green
237062 22040 27 11.000 A 0.000 A 106 0.00 0.00 0 0.00 106-Matte Black
238138 23587 27 11.000 A 0.000 A 106 0.00 0.00 0 0.00 106-Matte Black
215718 21970 28 18.000 A 0.000 A 370 0.00 0.00 0 0.00 370-Mint
237063 22040 28 11.000 A 0.000 A 206 0.00 0.00 0 0.00 206-Matte White
238139 23587 28 11.000 A 0.000 A 206 0.00 0.00 0 0.00 206-Matte White
215719 21970 30 18.000 A 0.000 A 380 0.00 0.00 0 0.00 380-Chartreuse
217241 22035 30 0.000 A 0.000 A 605 0.00 0.00 0 0.00 605-Textured Rust
217314 22040 30 11.000 A 0.000 A 307 0.00 0.00 0 0.00 307-Emerald Green
229359 22987 30 0.000 A 0.000 A G3 0.00 0.00 0 0.00 G3 Straight Arm
238113 23587 30 11.000 A 0.000 A 307 0.00 0.00 0 0.00 307-Emerald Green
237038 22035 32 11.000 A 0.000 A 106 0.00 0.00 0 0.00 106-Matte Black
242263 22040 32 11.000 A 0.000 A 311 0.00 0.00 0 0.00 311-Jadite
242267 23587 32 11.000 A 0.000 A 311 0.00 0.00 0 0.00 311-Jadite
237039 22035 33 11.000 A 0.000 A 206 0.00 0.00 0 0.00 206-Matte White
241171 22040 33 11.000 A 0.000 A 320 0.00 0.00 0 0.00 320-Fern Green
241181 23587 33 11.000 A 0.000 A 320 0.00 0.00 0 0.00 320-Fern Green
215720 21970 35 18.000 A 0.000 A 390 0.00 0.00 0 0.00 390-Teal
217242 22035 35 11.000 A 0.000 A 307 0.00 0.00 0 0.00 307-Emerald Green
217315 22040 35 11.000 A 0.000 A 370 0.00 0.00 0 0.00 370-Mint
229360 22987 35 0.000 A 0.000 A G4 0.00 0.00 0 0.00 G4 Straight Arm
238114 23587 35 11.000 A 0.000 A 370 0.00 0.00 0 0.00 370-Mint
242657 22035 36 11.000 A 0.000 A 311 0.00 0.00 0 0.00 311-Jadite
241261 22035 38 11.000 A 0.000 A 320 0.00 0.00 0 0.00 320-Fern Green
215721 21970 40 18.000 A 0.000 A 400 0.00 0.00 0 0.00 400-Barn Red
217243 22035 40 11.000 A 0.000 A 370 0.00 0.00 0 0.00 370-Mint
217316 22040 40 11.000 A 0.000 A 380 0.00 0.00 0 0.00 380-Chartreuse
229361 22987 40 4.000 A 0.000 A G1 0.00 0.00 0 0.00 G1 Straight Arm
238115 23587 40 11.000 A 0.000 A 380 0.00 0.00 0 0.00 380-Chartreuse
215722 21970 45 18.000 A 0.000 A 420 0.00 0.00 0 0.00 420-Orange
217244 22035 45 11.000 A 0.000 A 380 0.00 0.00 0 0.00 380-Chartreuse
217317 22040 45 11.000 A 0.000 A 390 0.00 0.00 0 0.00 390-Teal
229362 22987 45 4.000 A 0.000 A G14 0.00 0.00 0 0.00 G14 Straight Arm
238116 23587 45 11.000 A 0.000 A 390 0.00 0.00 0 0.00 390-Teal
241142 21970 48 18.000 A 0.000 A 430 0.00 0.00 0 0.00 430-Soft Clay
215723 21970 50 18.000 A 0.000 A 470 0.00 0.00 0 0.00 470-Watermelon
217245 22035 50 11.000 A 0.000 A 390 0.00 0.00 0 0.00 390-Teal
217318 22040 50 11.000 A 0.000 A 400 0.00 0.00 0 0.00 400-Barn Red
229363 22987 50 2.000 A 0.000 A G16 0.00 0.00 0 0.00 G16 Straight Arm
238117 23587 50 11.000 A 0.000 A 400 0.00 0.00 0 0.00 400-Barn Red
215724 21970 55 18.000 A 0.000 A 480 0.00 0.00 0 0.00 480-Blush Pink
217246 22035 55 11.000 A 0.000 A 400 0.00 0.00 0 0.00 400-Barn Red
217319 22040 55 11.000 A 0.000 A 420 0.00 0.00 0 0.00 420-Orange
229364 22987 55 2.000 A 0.000 A G17 0.00 0.00 0 0.00 G17 Straight Arm
238118 23587 55 11.000 A 0.000 A 420 0.00 0.00 0 0.00 420-Orange
241172 22040 58 11.000 A 0.000 A 430 0.00 0.00 0 0.00 430-Soft Clay
241182 23587 58 11.000 A 0.000 A 430 0.00 0.00 0 0.00 430-Soft Clay
215725 21970 60 18.000 A 0.000 A 490 0.00 0.00 0 0.00 490-Magenta
217247 22035 60 11.000 A 0.000 A 420 0.00 0.00 0 0.00 420-Orange
217320 22040 60 11.000 A 0.000 A 470 0.00 0.00 0 0.00 470-Watermelon
229365 22987 60 26.000 A 0.000 A G35 0.00 0.00 0 0.00 G35 Gooseneck Arm
238119 23587 60 11.000 A 0.000 A 470 0.00 0.00 0 0.00 470-Watermelon
241262 22035 63 11.000 A 0.000 A 430 0.00 0.00 0 0.00 430-Soft Clay
215726 21970 65 18.000 A 0.000 A 495 0.00 0.00 0 0.00 495-Sherbet Orange
217248 22035 65 11.000 A 0.000 A 470 0.00 0.00 0 0.00 470-Watermelon
217321 22040 65 11.000 A 0.000 A 480 0.00 0.00 0 0.00 480-Blush Pink
229366 22987 65 30.000 A 0.000 A G34 0.00 0.00 0 0.00 G34 Gooseneck Arm
238120 23587 65 11.000 A 0.000 A 480 0.00 0.00 0 0.00 480-Blush Pink
215727 21970 70 18.000 A 0.000 A 500 0.00 0.00 0 0.00 500-Buttery Yellow
217249 22035 70 11.000 A 0.000 A 480 0.00 0.00 0 0.00 480-Blush Pink
217322 22040 70 11.000 A 0.000 A 490 0.00 0.00 0 0.00 490-Magenta
229367 22987 70 16.000 A 0.000 A G5 0.00 0.00 0 0.00 G5 Gooseneck Arm
238121 23587 70 11.000 A 0.000 A 490 0.00 0.00 0 0.00 490-Magenta
215728 21970 75 18.000 A 0.000 A 570 0.00 0.00 0 0.00 570-Sunflower
217250 22035 75 11.000 A 0.000 A 490 0.00 0.00 0 0.00 490-Magenta
217323 22040 75 11.000 A 0.000 A 495 0.00 0.00 0 0.00 495-Sherbet Orange
229368 22987 75 21.000 A 0.000 A G25 0.00 0.00 0 0.00 G25 Gooseneck Arm
238122 23587 75 11.000 A 0.000 A 495 0.00 0.00 0 0.00 495-Sherbet Orange
215729 21970 80 18.000 A 0.000 A 600 0.00 0.00 0 0.00 600-Bronze
217251 22035 80 11.000 A 0.000 A 495 0.00 0.00 0 0.00 495-Sherbet Orange
217324 22040 80 11.000 A 0.000 A 500 0.00 0.00 0 0.00 500-Buttery Yellow
229369 22987 80 28.000 A 0.000 A G10 0.00 0.00 0 0.00 G10 Gooseneck Arm
238123 23587 80 11.000 A 0.000 A 500 0.00 0.00 0 0.00 500-Buttery Yellow
215730 21970 85 18.000 A 0.000 A 601 0.00 0.00 0 0.00 601-Chocolate
217252 22035 85 11.000 A 0.000 A 500 0.00 0.00 0 0.00 500-Buttery Yellow
217325 22040 85 11.000 A 0.000 A 570 0.00 0.00 0 0.00 570-Sunflower
229370 22987 85 97.000 A 0.000 A G19 0.00 0.00 0 0.00 G19 Gooseneck Arm
238124 23587 85 11.000 A 0.000 A 570 0.00 0.00 0 0.00 570-Sunflower
217253 22035 90 11.000 A 0.000 A 570 0.00 0.00 0 0.00 570-Sunflower
217326 22040 90 11.000 A 0.000 A 600 0.00 0.00 0 0.00 600-Bronze
229371 22987 90 190.000 A 0.000 A G65 0.00 0.00 0 0.00 G65 Gooseneck Arm
238125 23587 90 11.000 A 0.000 A 600 0.00 0.00 0 0.00 600-Bronze
241143 21970 90 18.000 A 0.000 A 607 0.00 0.00 0 0.00 607-Taupe
215732 21970 95 18.000 A 0.000 A 615 0.00 0.00 0 0.00 615-Oil-Rubbed Bronze
217254 22035 95 11.000 A 0.000 A 600 0.00 0.00 0 0.00 600-Bronze
217327 22040 95 11.000 A 0.000 A 601 0.00 0.00 0 0.00 601-Chocolate
229372 22987 95 158.000 A 0.000 A G64 0.00 0.00 0 0.00 G64 Gooseneck Arm
238126 23587 95 11.000 A 0.000 A 601 0.00 0.00 0 0.00 601-Chocolate
241144 21970 98 18.000 A 0.000 A 630 0.00 0.00 0 0.00 630-Beige
241173 22040 98 11.000 A 0.000 A 607 0.00 0.00 0 0.00 607-Taupe
241183 23587 98 11.000 A 0.000 A 607 0.00 0.00 0 0.00 607-Taupe
215733 21970 100 18.000 A 0.000 A 700 0.00 0.00 0 0.00 700-Royal Blue
217255 22035 100 11.000 A 0.000 A 601 0.00 0.00 0 0.00 601-Chocolate
217328 22040 100 11.000 A 0.000 A 615 0.00 0.00 0 0.00 615-Oil-Rubbed Bronze
229373 22987 100 8.000 A 0.000 A G12 0.00 0.00 0 0.00 G12 Gooseneck Arm
238127 23587 100 11.000 A 0.000 A 615 0.00 0.00 0 0.00 615-Oil-Rubbed Bronze
241263 22035 103 11.000 A 0.000 A 607 0.00 0.00 0 0.00 607-Taupe
215734 21970 105 18.000 A 0.000 A 705 0.00 0.00 0 0.00 705-Navy
217256 22035 105 11.000 A 0.000 A 615 0.00 0.00 0 0.00 615-Oil-Rubbed Bronze
229374 22987 105 10.000 A 0.000 A G13 0.00 0.00 0 0.00 G13 Gooseneck Arm
241174 22040 105 11.000 A 0.000 A 630 0.00 0.00 0 0.00 630-Beige
241184 23587 105 11.000 A 0.000 A 630 0.00 0.00 0 0.00 630-Beige
241264 22035 108 11.000 A 0.000 A 630 0.00 0.00 0 0.00 630-Beige
215735 21970 110 18.000 A 0.000 A 790 0.00 0.00 0 0.00 790-Lavender
217257 22035 110 11.000 A 0.000 A 700 0.00 0.00 0 0.00 700-Royal Blue
217329 22040 110 11.000 A 0.000 A 700 0.00 0.00 0 0.00 700-Royal Blue
229375 22987 110 23.000 A 0.000 A G32 0.00 0.00 0 0.00 G32 Gooseneck Arm
238128 23587 110 11.000 A 0.000 A 700 0.00 0.00 0 0.00 700-Royal Blue
242136 21970 112 18.000 A 0.000 A 710 0.00 0.00 0 0.00 710-Cobalt Blue
242137 21970 113 18.000 A 0.000 A 715 0.00 0.00 0 0.00 715-Delphite Blue
215736 21970 115 18.000 A 0.000 A 800 0.00 0.00 0 0.00 800-Industrial Grey
217258 22035 115 11.000 A 0.000 A 705 0.00 0.00 0 0.00 705-Navy
217330 22040 115 11.000 A 0.000 A 705 0.00 0.00 0 0.00 705-Navy
238129 23587 115 11.000 A 0.000 A 705 0.00 0.00 0 0.00 705-Navy
242658 22035 116 11.000 A 0.000 A 710 0.00 0.00 0 0.00 710-Cobalt Blue
242659 22035 117 11.000 A 0.000 A 715 0.00 0.00 0 0.00 715-Delphite Blue
242264 22040 118 11.000 A 0.000 A 710 0.00 0.00 0 0.00 710-Cobalt Blue
242268 23587 118 11.000 A 0.000 A 710 0.00 0.00 0 0.00 710-Cobalt Blue
243002 22035 118 11.000 A 0.000 A 790 0.00 0.00 0 0.00 790-Lavender
230712 22035 119 11.000 A 0.000 A 800 0.00 0.00 0 0.00 800-Industrial Grey
242265 22040 119 11.000 A 0.000 A 715 0.00 0.00 0 0.00 715-Delphite Blue
242269 23587 119 11.000 A 0.000 A 715 0.00 0.00 0 0.00 715-Delphite Blue
215737 21970 120 18.000 A 0.000 A 805 0.00 0.00 0 0.00 805-Charcoal Granite
217259 22035 120 11.000 A 0.000 A 805 0.00 0.00 0 0.00 805-Charcoal Granite
217331 22040 120 11.000 A 0.000 A 790 0.00 0.00 0 0.00 790-Lavender
229377 22987 120 35.000 A 0.000 A G2 0.00 0.00 0 0.00 G2 Gooseneck Arm
238130 23587 120 11.000 A 0.000 A 790 0.00 0.00 0 0.00 790-Lavender
242660 22035 122 11.000 A 0.000 A 810 0.00 0.00 0 0.00 810-Graphite
241265 22035 123 11.000 A 0.000 A 815 0.00 0.00 0 0.00 815-Light Grey
242138 21970 123 18.000 A 0.000 A 810 0.00 0.00 0 0.00 810-Graphite
217332 22040 125 11.000 A 0.000 A 800 0.00 0.00 0 0.00 800-Industrial Grey
229378 22987 125 39.000 A 0.000 A G36 0.00 0.00 0 0.00 G36 Gooseneck Arm
238131 23587 125 11.000 A 0.000 A 800 0.00 0.00 0 0.00 800-Industrial Grey
241145 21970 125 18.000 A 0.000 A 815 0.00 0.00 0 0.00 815-Light Grey
217333 22040 130 11.000 A 0.000 A 805 0.00 0.00 0 0.00 805-Charcoal Granite
229379 22987 130 25.000 A 0.000 A G7 0.00 0.00 0 0.00 G7 Gooseneck Arm
238132 23587 130 11.000 A 0.000 A 805 0.00 0.00 0 0.00 805-Charcoal Granite
242266 22040 132 11.000 A 0.000 A 810 0.00 0.00 0 0.00 810-Graphite
242270 23587 132 11.000 A 0.000 A 810 0.00 0.00 0 0.00 810-Graphite
241175 22040 133 11.000 A 0.000 A 815 0.00 0.00 0 0.00 815-Light Grey
241185 23587 133 11.000 A 0.000 A 815 0.00 0.00 0 0.00 815-Light Grey
229380 22987 135 32.000 A 0.000 A G9 0.00 0.00 0 0.00 G9 Gooseneck Arm
229381 22987 140 141.000 A 0.000 A G40 0.00 0.00 0 0.00 G40 Gooseneck Arm