SELECT 
  cscart_images_links.*, 
  cscart_images.image_path, 
  cscart_common_descriptions.description AS alt, 
  cscart_images.image_x, 
  cscart_images.image_y, 
  cscart_images.image_id as images_image_id 
FROM 
  cscart_images_links 
  LEFT JOIN cscart_images ON cscart_images_links.detailed_id = cscart_images.image_id 
  LEFT JOIN cscart_common_descriptions ON cscart_common_descriptions.object_id = cscart_images.image_id 
  AND cscart_common_descriptions.object_holder = 'images' 
  AND cscart_common_descriptions.lang_code = 'en' 
WHERE 
  cscart_images_links.object_type = 'product' 
  AND cscart_images_links.type = 'A' 
  AND cscart_images_links.object_id IN (
    63430, 60978, 60980, 60979, 61620, 61621, 
    60976, 60975, 60981, 63231, 63234, 
    63816
  ) 
ORDER BY 
  cscart_images_links.position, 
  cscart_images_links.pair_id

Query time 0.00118

JSON explain

{
  "query_block": {
    "select_id": 1,
    "read_sorted_file": {
      "filesort": {
        "sort_key": "cscart_images_links.position, cscart_images_links.pair_id",
        "table": {
          "table_name": "cscart_images_links",
          "access_type": "range",
          "possible_keys": ["object_id"],
          "key": "object_id",
          "key_length": "81",
          "used_key_parts": ["object_id", "object_type", "type"],
          "rows": 72,
          "filtered": 100,
          "index_condition": "cscart_images_links.object_type = 'product' and cscart_images_links.`type` = 'A' and cscart_images_links.object_id in (63430,60978,60980,60979,61620,61621,60976,60975,60981,63231,63234,63816)"
        }
      }
    },
    "table": {
      "table_name": "cscart_images",
      "access_type": "eq_ref",
      "possible_keys": ["PRIMARY"],
      "key": "PRIMARY",
      "key_length": "3",
      "used_key_parts": ["image_id"],
      "ref": ["cscart_migrate.cscart_images_links.detailed_id"],
      "rows": 1,
      "filtered": 100,
      "attached_condition": "trigcond(cscart_images_links.detailed_id = cscart_images.image_id)"
    },
    "table": {
      "table_name": "cscart_common_descriptions",
      "access_type": "eq_ref",
      "possible_keys": ["PRIMARY"],
      "key": "PRIMARY",
      "key_length": "107",
      "used_key_parts": ["object_id", "lang_code", "object_holder"],
      "ref": ["cscart_migrate.cscart_images.image_id", "const", "const"],
      "rows": 1,
      "filtered": 100,
      "attached_condition": "trigcond(cscart_common_descriptions.object_id = cscart_images.image_id and cscart_common_descriptions.object_holder = 'images' and cscart_common_descriptions.lang_code = 'en' and trigcond(cscart_images.image_id is not null))"
    }
  }
}

Result

pair_id object_id object_type image_id detailed_id type position image_type show_gallery gallery_category_id image_path alt image_x image_y images_image_id
13539 60981 product 0 23989 A 0 D 0 0 Wilcox_2-Light_Vanity_Sconce_-_Barn_Light_Electric_-_Galvanized.png 10" Wilcox Vanity Sconce, 975-Galvanized 1000 1000 23989
13554 60980 product 0 24019 A 0 D 0 0 8_inch_wesco_double_vanity_gooseneck_975_galvanized.jpg 8" Wilcox Double Vanity, 975-Galvanized 600 600 24019
13775 60980 product 0 24460 A 0 D 0 0 8_inch_wesco_double_vanity_gooseneck_300_dark_green.jpg 8" Wilcox Double Vanity, 100-Black 600 600 24460
18084 60975 product 0 29713 A 0 D 0 0 Austin_2-Light_Vanity_Sconce__-_Barn_Light_Electric_-_Black.png 8" Austin 2-Light Vanity Sconce, 100-Black 1000 1000 29713
18085 60975 product 0 29714 A 0 D 0 0 Austin_2-Light_Vanity_Sconce__-_Barn_Light_Electric_-_Galvanized.png 10" Austin 2-Light Vanity Sconce, 975-Galvanized 1000 1000 29714
18087 60978 product 0 29716 A 0 D 0 0 Union_2-Light_Vanity_Sconce_-_Barn_Light_Electric_-_Dark_Green.png 10" Union Vanity Light, 300-Dark Green 1000 1000 29716
18088 60978 product 0 29717 A 0 D 0 0 Union_2-Light_Vanity_Sconce_-_Barn_Light_Electric_-_Black.png 10" Union Vanity Light, 100-Black 1000 1000 29717
18090 60981 product 0 29719 A 0 D 0 0 Wilcox_2-Light_Vanity_Sconce_-_Barn_Light_Electric_-_Dark_Green.png 8" Wilcox Vanity Sconce, 300-Dark Green 1000 1000 29719
18186 60979 product 0 29815 A 0 D 0 0 10_inch_universal_double_vanity_gooseneck_300_dark_green.jpg 10" Union Gooseneck Double Vanity Light, 300-Dark Green 600 600 29815
18187 60979 product 0 29816 A 0 D 0 0 10_inch_universal_double_vanity_gooseneck_975_galvanized.jpg 10" Union Gooseneck Double Vanity Light, 975-Galvanized 600 600 29816
21982 61620 product 0 33874 A 0 D 0 0 schoolhouse-primary-vanity-2-light-small-glass-clear-705-navy-700-royal-blue-double-painted-band.jpg Primary 2-Light Schoolhouse Vanity Light, Clear Glass, 705-Navy Mounting and Fitter Finish, Double Painted Band in 700-Royal Blue 1000 1000 33874
24954 63231 product 0 37030 A 0 D 0 0 atomic-straight-arm-double-vanity-flared-100-black-975-galvanized-CGG-FST.jpg Industrial Guard Double Vanity Light, 100-Black, CGG-Standard Cast Guard, FST-Frosted Glass 1000 1000 37030
26045 63430 product 0 38207 A 0 D 0 0 lang-machine-age-4-light-black-red-cord.jpg Lang Machine Age 4-Light Wall Sconce, Sockets in Black with No Switch, TBK-Black Cotton Twist Cord, 1890 Era Edison Bulbs 600 600 38207
27494 63816 product 0 39671 A 0 D 0 0 strip-light-vanity-3-light-galvanized-half-chrome.jpg Vanity Strip Light, 3-Light, 975-Galvanized, Half-Chrome Bulbs 600 600 39671
31648 60976 product 0 43881 A 0 C 0 0 residential_austin_gooseneck_double_vanity_light_white_above_bathroom_mirror.jpg Austin Gooseneck Double Vanity Light, 10" Shades, 200-White | Photo Courtesy of Homeowner 1994 2991 43881
53588 60981 product 0 65821 A 0 C 0 0 wilcox_2light_vanity_10in_jadite.jpg 10” Wilcox Vanity Sconce, 311-Jadite PTMP | Photo Courtesy of Houses and Barns by John Libby and Izzy Bouchard Photography 5939 4243 65821
53589 60981 product 0 65822 A 0 C 0 0 wilcox_2light_vanity_10in_jadite3.jpg 10” Wilcox Vanity Sconce, 311-Jadite PTMP | Photo Courtesy of Houses and Barns by John Libby and Izzy Bouchard Photography 4386 6140 65822
61372 60981 product 0 73605 A 0 C 0 0 Wilcox_2-Light_Vanity_Light_-_Barn_Light_Electric_-_Bathroom_Vanity_Sco.jpg 8” Wilcox Vanity Sconce, 605-Rust | Photo Courtesy of Houses and Barns by Stacy Mother from Living Interiors of Connecticut, LLC 2448 3264 73605
63918 61621 product 0 76151 A 0 D 0 0 schoolhouse-primary-vanity-3-light-small-glass-clear-975-galvanized.jpg Primary 3-Light Schoolhouse Vanity Light, Clear Glass, 975-Galvanized Mounting and Fitter Finish 1000 1000 76151
65326 63234 product 0 77559 A 0 D 0 0 CGG-vanities-3-light-straight-arm-topless-400-barn-red-CGG-FST.jpg Industrial Guard Triple Vanity Light, 400-Barn Red, Topless Shade, CGG-Standard Cast Gard, FST-Frosted Glass 1000 1000 77559
66470 63234 product 0 78703 A 0 C 0 0 IMG_1879-residential-interior-lighting-on-bathroom-vanity-Industrial-Guard-Triple-Vanity-Light-715-Delphite-Blue-No-Shade-CGG-Clear-Glass.jpg Industrial Guard Triple Vanity Light, 715-Delphite Blue, No Shade, Standard Cast Guard, Clear Glass | Customer Submission 3009 3866 78703
67215 60980 product 0 79448 A 0 C 0 0 20230117_094710-residential-interior-lighting-on-bathroom-vanity-Wilcox-2-Light-Vanity-10in-380-Chartreuse.jpg 10" Wilcox Double Vanity, 380-Chartreuse | Customer Submission 2981 3633 79448
13577 60976 product 0 24065 A 1 D 0 0 8_inch_austin_double_vanity_gooseneck_100_black.jpg Austin Gooseneck Double Vanity Light, 8" Shades, 100-Black 600 600 24065
24962 63234 product 0 37038 A 1 D 0 0 CGG-vanities-3-light-straight-arm-flared-100-black-CGG-RIB.jpg Industrial Guard Triple Vanity Light, 100-Black, Flared Shade, CGG-Standard Cast Guard, RIB-Ribbed Glass 1000 1000 37038
26040 63430 product 0 38202 A 1 D 0 0 lang-machine-age-4-light-gold-black-cord1.jpg Lang 4-Light Wall Sconce, Sockets in Brass with No Switch, TBK-Black Cotton Twist Cord, Victorian 25W Edison Bulbs 600 600 38202
63921 61621 product 0 76154 A 1 D 0 0 schoolhouse-primary-vanity-3-light-small-glass-opaque-500-buttery-yellow.jpg Primary 3-Light Schoolhouse Vanity Light, Opaque Glass, 500-Buttery Yellow Mounting and Fitter Finish 1000 1000 76154
63925 61620 product 0 76158 A 1 D 0 0 schoolhouse-primary-vanity-2-light-small-glass-opaque-500-buttery-yellow.jpg Primary 2-Light Schoolhouse Vanity Light, Opaque Glass, 500-Buttery Yellow Mounting and Fitter Finish 1000 1000 76158
65392 63231 product 0 77625 A 1 D 0 0 2-Arm-Vanities-Straight-On-arm-400-barn-Red-CGG-FST.jpg Industrial Guard Double Vanity Light, 400-Barn Red, CGG-Standard Cast Guard, FST-Frosted Glass 1000 1000 77625
68286 63816 product 0 80519 A 1 C 0 0 Blush_Pink_Vanity_Strip_Light_-_Barn_Light_Electric.JPG Vanity Strip Light, 5-Light, 480-Blush Pink | Photo Courtesy of Homeowner 2924 3719 80519
26042 63430 product 0 38204 A 2 D 0 0 lang-machine-age-4-light-copper-black-white-cord1.jpg Lang 4 Light Wall Sconce, Sockets in Copper with No Switch, TBW-Black & White Chevron Twist Cord, 1890 Era Edison Bulbs 600 600 38204
26248 60975 product 0 38411 A 2 D 0 0 austin_vanity-teal.jpg 10" Austin 2-Light Vanity Sconce, 390-Teal 669 551 38411
52007 63816 product 0 64240 A 2 C 0 0 vanity_strip_lights.jpg Vanity Stripe Light, 5-Light, 100-Black 750 863 64240
63919 61621 product 0 76152 A 2 D 0 0 schoolhouse-primary-vanity-3-light-small-glass-opaque-100-black-311-jadite-single-painted-band.jpg Primary 3-Light Schoolhouse Vanity Light, Opaque Glass, 100-Black Mounting and Fitter Finish, Single Painted Band, 311-Jadite 1000 1000 76152
63922 61620 product 0 76155 A 2 D 0 0 schoolhouse-primary-vanity-2-light-small-glass-opaque-100-black-311-jadite-single-painted-band.jpg Primary 2-Light Schoolhouse Vanity Light, Opaque Glass, 100-Black Mounting and Fitter Finish, Single Painted Band in 311-Jadite 1000 1000 76155
65328 63234 product 0 77561 A 2 D 0 0 CGG-vanities-3-light-straight-arm-warehouse-715-delphite-WGG-FST.jpg Industrial Guard Triple Vanity Light, 715-Delphite, Warehouse Shade, WGG-Wire Guard, FST-Frosted Glass 1000 1000 77561
65391 63231 product 0 77624 A 2 D 0 0 2-Arm-Vanities-Straight-On-arm-307-emerald-CGG-RIB.jpg Industrial Guard Double Vanity Light, 307-Emerald Green, CGG-Standard Cast Guard, RIB-Ribbed Glass 1000 1000 77624
21983 61620 product 0 33875 A 3 D 0 0 schoolhouse-primary-vanity-2-light-small-glass-clear-975-galvanized.jpg Primary 2-Light Schoolhouse Vanity Light, Clear Glass, 975-Galvanized Mounting and Fitter Finish 1000 1000 33875
23152 61621 product 0 35063 A 3 D 0 0 schoolhouse-primary-vanity-3-light-small-glass-clear-715-delphite-triple-painted-band.jpg Primary 3-Light Schoolhouse Vanity Light, Clear Glass, 715-Delphite Mounting and Fitter Finish, Triple Painted Band 1000 1000 35063
27799 63816 product 0 39976 A 3 C 0 0 Strip-light-vanity.jpg Vanity Strip Light, 3-Light, 975-Galvanized, Nostalgic Edison 1890 Era 40W Bulbs 750 864 39976
32593 63430 product 0 44826 A 3 D 0 0 lang-machine-age-4-light-chrome-black1-1.jpg Lang Machine Age 4-Light Wall Sconce, TBK-Black Cotton Twist Cord, NK-Nickel Sockets with Knob Switch, 1890 Era Edison Bulbs 600 600 44826
65325 63234 product 0 77558 A 3 D 0 0 CGG-vanities-3-light-straight-arm-topless-307-emerald-green-CGG-RIB.jpg Industrial Guard Triple Vanity Light, 307-Emerald Green, Topless Shade, CGG-Standard Cast Guard, RIB-Ribbed Glass 1000 1000 77558
65393 63231 product 0 77626 A 3 D 0 0 2-Arm-Vanities-Straight-On-arm-480-blush-pink-TGG-FST.jpg Industrial Guard Double Vanity Light, 480-Blush Pink, TGG-Heavy Duty Cast Guard, FST-Frosted Glass 1000 1000 77626
23151 61621 product 0 35062 A 4 D 0 0 schoolhouse-primary-vanity-3-light-small-glass-clear-705-navy-700-royal-blue-double-painted-band.jpg Primary 3-Light Schoolhouse Vanity Light, Clear Glass, 705-Navy Mounting and Fitter Finish, Double Painted Band in 700-Royal Blue 1000 1000 35062
26247 60975 product 0 38410 A 4 D 0 0 austin_vanity-magenta.jpg 10" Austin 2-Light Vanity Sconce, 480-Magenta 669 551 38410
27495 63816 product 0 39672 A 4 D 0 0 strip-light-vanity-5-light-white-half-chrome.jpg Vanity Strip Light, 5-Light, 200-White, Half-Chrome Bulbs 600 600 39672
31665 61620 product 0 43898 A 4 D 0 0 schoolhouse-primary-vanity-2-light-small-glass-clear-805-charcoal-granite-200-white-single-painted-band.jpg Primary 2-Light Schoolhouse Vanity Light, Clear Glass, 805-Charcoal Granite Mounting and Fitter Finish, Single Painted Band in 200-White 1000 1000 43898
32150 63231 product 0 44383 A 4 D 0 0 2-Arm-Vanities-Straight-On-arm-200-white-WGG-RIB.jpg Industrial Guard Double Vanity Light, 200-White, WGG-Wire Guard, RIB-Ribbed Glass 1000 1000 44383
32153 63234 product 0 44386 A 4 D 0 0 CGG-vanities-3-light-straight-arm-flared-200-white-TGG-FST.jpg Industrial Guard Triple Vanity Light, 200-White, Flared Shade, TGG-Heavy Duty Cast Guard, FST-Frosted Glass 1000 1000 44386
32594 63430 product 0 44827 A 4 D 0 0 machine-age-4-light-copper-Tala-Bulb-6W-2500k-Globe.jpg Lang Machine Age 4-Light Wall Sconce, TBW-Black & White Cotton Twist Cord, CS-Copper Socket with No Knob | Shown with Globe Tala Lamps 1000 1000 44827
26043 63430 product 0 38205 A 5 C 0 0 Untitled-1.jpg Lang 4 Light Wall Sconce, Sockets in Brass with No Switch, TBK-Black Cotton Twist Cord, Victorian 25W Edison Bulbs 600 600 38205
27498 63816 product 0 39675 A 5 D 0 0 strip-light-vanity-3-light-white-edison.jpg Vanity Stripe Light, 3-Light, 975-Galvanized, Nostalgic Edison 1890 Era 40W Bulbs 600 600 39675
63920 61621 product 0 76153 A 5 D 0 0 schoolhouse-primary-vanity-3-light-small-glass-opaque-200-white-307-emerald-green-double-painted-band.jpg Primary 3-Light Schoolhouse Vanity Light, Opaque Glass, 200-White Mounting and Fitter Finish, Double Painted Band in 307-Emerald Green 1000 1000 76153
63923 61620 product 0 76156 A 5 D 0 0 schoolhouse-primary-vanity-2-light-small-glass-opaque-200-white-307-emerald-green-double-painted-band.jpg Primary 2-Light Schoolhouse Vanity Light, Opaque Glass, 200-White Mounting and Fitter Finish, Double Painted Band in 307-Emerald Green 1000 1000 76156
65327 63234 product 0 77560 A 5 D 0 0 CGG-vanities-3-light-straight-arm-topless-500-buttery-yellow-CGG-RIB.jpg Industrial Guard Triple Vanity Light, 500-Buttery Yellow, Topless Shade, CGG-Standard Cast Guard, RIB-Ribbed Glass 1000 1000 77560
65394 63231 product 0 77627 A 5 D 0 0 2-Arm-Vanities-Straight-On-arm-705-navy-CGG-CLR.jpg Industrial Guard Double Vanity Light, 705-Navy, CGG-Standard Cast Guard, CLR-Clear Glass 1000 1000 77627
66468 63234 product 0 78701 A 5 C 0 0 IMG_0851-residential-interior-lighting-on-bathroom-vanity-Industrial-Guard-Triple-Vanity-Light-715-Delphite-Blue-No-Shade-CGG-Clear-Glass.jpg Industrial Guard Triple Vanity Light, 715-Delphite Blue, No Shade, Standard Cast Guard, Clear Glass | Customer Submission 4032 1690 78701
27497 63816 product 0 39674 A 6 D 0 0 strip-light-vanity-5-light-galvanized-edison.jpg Vanity Stripe Light, 5-Light, 975-Galvanized, Nostalgic Edison 1890 Era 40W Bulbs 600 600 39674
32475 63430 product 0 44708 A 6 C 0 0 The_Lang_Machine_Age_4-Light_Wall_Light.jpg Lang Machine Age 4-Light Wall Sconce, CSR-Red Cloth Cord, CS-Copper Sockets with No Switches | Photo Courtesy of Homeowner 768 1024 44708
38470 63231 product 0 50703 A 6 C 0 0 double_vanity_lights-512x768.jpg Industrial Guard Double Vanity Light, 570-Sunflower, CGG-Standard Cast Guard, CLR-Clear Glass | Photo Courtesy of Lolly Jane 512 768 50703
63917 61621 product 0 76150 A 6 D 0 0 schoolhouse-primary-vanity-3-light-small-glass-clear-805-charcoal-granite-200-white-single-painted-band.jpg Primary 3-Light Schoolhouse Vanity Light, Clear Glass, 805-Charcoal Granite Mounting and Fitter Finish, Single Painted Band in 200-White 1000 1000 76150
63924 61620 product 0 76157 A 6 D 0 0 schoolhouse-primary-vanity-2-light-small-glass-opaque-400-barn-red-triple-painted-band.jpg Primary 2-Light Schoolhouse Vanity Light, Opaque Glass, 400-Barn Red Mounting and Fitter Finish, Triple Painted Band 1000 1000 76157
52008 63816 product 0 64241 A 7 C 0 0 vanity_strip_lighting_american_made-667x768.jpg Vanity Stripe Light, 3-Light, 975-Galvanized 667 768 64241
55739 63231 product 0 67972 A 7 C 0 0 Industrial_Guard_Double_Vanity_Light_-_Barn_Light_Electric.jpg Industrial Guard Double Vanity Light, 570-Sunflower, CGG-Standard Cast Guard, CLR-Clear Glass | Photo Courtesy of Lolly Jane 683 1024 67972
60295 61621 product 0 72528 A 7 C 0 0 Schoolhouse_3-Light_Vanity_Light_-_Barn_Light_Electric_-_Commercial_Lighting.png Primary 3-Light Schoolhouse Vanity Light, Opaque Glass, 100-Black Mounting and Fitter Finish, No Painted Band | Photo Courtesy of Ukrops Food Hall in Richmond, VA, Urban Core Development, Lighting Environments VA and 510 Architects 575 431 72528
68157 61620 product 0 80390 A 7 C 0 0 IMG_4573-residential-interior-bathroom-lighting-on-vanity-Primary-Schoolhouse-2-Light-Vanity-Small-Opaque-100-Black.jpg Primary 2-Light Schoolhouse Vanity, Small Opaque, 100-Black | Photo Courtesy of Hector Sanchez 3007 3695 80390
38471 63231 product 0 50704 A 8 C 0 0 rustic_industrial_bathroom_lighting-512x768.jpg Industrial Guard Double Vanity Light, 570-Sunflower, CGG-Standard Cast Guard, CLR-Clear Glass | Photo Courtesy of Lolly Jane 512 768 50704
52009 63816 product 0 64242 A 8 D 0 0 strip-light-vanity-5-light-black-half-chrome.jpg Vanity Strip Light, 5-Light, 100-Black, Half-Chrome Bulbs 475 475 64242
68156 61620 product 0 80389 A 8 C 0 0 Minden_bathroom_with_lights_on-residential-interior-bathroom-Primary-schoolhouse-2-light-vanity-small-opaque-glass-100-black.jpg Primary 2-Light Schoolhouse Vanity, Small Opaque Glass, 100-Black | Photo Courtesy of Hector Sanchez 1895 2842 80389
31941 61620 product 0 44174 A 9 C 0 0 Unknown-1.jpeg Primary 2-Light Schoolhouse Vanity Light, Opaque Glass, Mounting and Fitter in 200-White, Triple Painted Band in 100-Black | Photo Courtesy of Homeowner 2848 4288 44174
58770 63231 product 0 71003 A 9 C 0 0 Industrial_Guard_Double_Vanity_Light_-_Barn_Light_Electric_-_Modern_Vanity_Lighting.jpg Industrial Guard Double Vanity Light, 200-White, FS-Flared Shade, WGG-Wire Guard in 975-Galvanized, Frosted Glass | Customer Submission 3024 4032 71003
40471 63231 product 0 52704 A 10 C 0 0 industrial_guard_double_vanity_light_bronze_FS_cgg_ribbed2.jpg Industrial Guard Double Vanity Light, 600-Bronze, FS-Flared Shade, CGG-Standard Cast Guard, Ribbed Glass | Customer Submission 1512 2016 52704
54174 61620 product 0 66407 A 10 C 0 0 vanity_lighting_schoolhouse_vanity_lights.jpg Primary 2-Light Schoolhouse Vanity Light, Opaque Glass, Mounting and Fitter in 200-White, Triple Painted Band in 100-Black | Photo Courtesy of Homeowner 652 798 66407