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 (64903, 64909, 64875, 62977) 
ORDER BY 
  cscart_images_links.position, 
  cscart_images_links.pair_id

Query time 0.00106

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": 40,
          "filtered": 100,
          "index_condition": "cscart_images_links.object_type = 'product' and cscart_images_links.`type` = 'A' and cscart_images_links.object_id in (64903,64909,64875,62977)"
        }
      }
    },
    "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
23751 62977 product 0 35682 A 0 D 0 0 Schoolhouse-Kao-Primary-Small-Opaque-triple-band-715-delphite.jpg Kao Primary Schoolhouse Flush Mount, 715-Delphite, Small Opaque Glass, Triple Painted Band 1000 1000 35682
46914 64903 product 0 59147 A 0 D 0 0 schoolhouse-acorn-flush-opaque-stripe-PB5-dark-green.jpg Acorn Flush Mount, 300-Dark Green, Opaque Glass, Three Painted Band, 300-Dark Green 1000 1000 59147
47927 64875 product 0 60160 A 0 D 0 0 schoolhouse-globe-flush-semi-opaque-stripe-none-copper-weathered.jpg Round Semi-Flush, 996-Natural Weathered Copper, Opaque Glass, No Painted Band 1000 1000 60160
23659 62977 product 0 35587 A 1 D 0 0 Schoolhouse-Kao-Primary-Small-Opaque-380-chartreuse_dxcw-0x.jpg Kao Primary Schoolhouse Flush Mount, 380-Chartreuse, Small Opaque Glass 1000 1000 35587
46904 64909 product 0 59137 A 1 D 0 0 schoolhouse-drum-flush-opaque-stripe-none-buttery-yellow.jpg Drum Flush Mount, 500-Buttery Yellow, Opaque Glass, No Painted Band 1000 1000 59137
46915 64903 product 0 59148 A 1 D 0 0 schoolhouse-acorn-flush-opaque-stripe-PB6-barn-red.jpg Acorn Flush Mount, 400-Barn Red, Opaque Glass, Five Painted Band, 400-Barn Red 1000 1000 59148
47929 64875 product 0 60162 A 1 D 0 0 schoolhouse-globe-flush-semi-opaque-stripe-PB10-emerald-green.jpg Round Semi-Flush, 307-Emerald Green, Opaque Glass, Two Painted Band, 307-Emerald Green 1000 1000 60162
29821 62977 product 0 42044 A 2 D 0 0 Schoolhouse-Kao-Primary-Small-Opaque-390-teal-double-band.jpg Kao Primary Schoolhouse Flush Mount, 390-Teal, Double Painted Band 1000 1000 42044
46905 64909 product 0 59138 A 2 D 0 0 schoolhouse-drum-flush-clear-stripe-PB8-jadite-bulb-chrome.jpg Drum Flush Mount, 311-Jadite, Clear Glass, Four Painted Band, 311-Jadite, Shown with G30 Half-Chrome Bulb 1000 1000 59138
46916 64903 product 0 59149 A 2 D 0 0 schoolhouse-acorn-flush-clear-stripe-none-oil-rubbed-bronze-bulb-G30.jpg Acorn Flush Mount, 615-Oil-Rubbed Bronze, Clear Glass, No Painted Band, Shown with G30 Bulb 1000 1000 59149
47930 64875 product 0 60163 A 2 D 0 0 schoolhouse-globe-flush-semi-opaque-stripe-PB12-brass-raw-black.jpg Round Semi-Flush, 997-Natural Raw Brass, Opaque Glass, Four Painted Band, 100-Black 1000 1000 60163
31668 62977 product 0 43901 A 3 D 0 0 Schoolhouse-Kao-Primary-Large-Clear-615-oirl-rubbed-bronze.jpg Kao Primary Schoolhouse Flush Mount, 615-Oil Rubbed Bronze, Large Clear Glass 1000 1000 43901
46906 64909 product 0 59139 A 3 D 0 0 schoolhouse-drum-flush-opaque-stripe-PB7-delphite.jpg Drum Flush Mount, 715-Delphite Blue, Opaque Glass, Single Painted Band, 715-Delphite Blue 1000 1000 59139
46917 64903 product 0 59150 A 3 D 0 0 schoolhouse-acorn-flush-opaque-stripe-PB5-delphite.jpg Acorn Flush Mount, 715-Delphite Blue, Opaque Glass, Three Painted Band, 715-Delphite Blue 1000 1000 59150
47932 64875 product 0 60165 A 3 D 0 0 schoolhouse-globe-flush-semi-clear-stripe-PB11-black-bulb-G30.jpg Round Semi-Flush, 100-Black, Clear Glass, Three Painted Band, 100-Black, Shown with G30 Bulb 1000 1000 60165
23791 62977 product 0 35722 A 4 D 0 0 Schoolhouse-Kao-Primary-Small-Opaque-500-buttery-yellow-single-stripe.jpg Kao Primary Schoolhouse Flush Mount, 500-Buttery Yellow, Small Opaque Glass, Single Painted Band 1000 1000 35722
46908 64909 product 0 59141 A 4 D 0 0 schoolhouse-drum-flush-clear-stripe-none-galvanized-bulb-1890.jpg Drum Flush Mount, 975-Galvanized, Clear Glass, No Painted Band, Shown with 1890 Edison Style Bulb 1000 1000 59141
46918 64903 product 0 59151 A 4 D 0 0 schoolhouse-acorn-flush-clear-stripe-PB6-charcoal-granite-black.jpg Acorn Flush Mount, 805-Charcoal Granite, Clear Glass, Five Painted Band, 100-Black, Shown with G40 Bulb 1000 1000 59151
47933 64875 product 0 60166 A 4 D 0 0 schoolhouse-globe-flush-semi-clear-stripe-none-galvanized-bulb-round.jpg Round Semi-Flush, 975-Galvanized, Clear Glass, No Painted Band, Shown with G40 Bulb 1000 1000 60166
31669 62977 product 0 43902 A 5 D 0 0 Schoolhouse-Kao-Primary-Small-Clear-700-royal-double-band-black.jpg Kao Primary Schoolhouse Flush Mount, 700-Royal, Small Clear Glass, Double Painted Band 1000 1000 43902
46909 64909 product 0 59142 A 5 D 0 0 schoolhouse-drum-flush-clear-stripe-PB9-black-bulb-chrome.jpg Drum Flush Mount, 100-Black, Clear Glass, Seven Painted Band, 100-Black, Shown with G30 Half-Chrome Bulb 1000 1000 59142
47931 64875 product 0 60164 A 5 D 0 0 schoolhouse-globe-flush-semi-clear-stripe-PB10-delphite-bulb-1890.jpg Round Semi-Flush, 715-Delphite Blue, Clear Glass, Two Painted Band, 715-Delphite Blue, Shown with 1890 Edison Bulb 1000 1000 60164
61196 64903 product 0 73429 A 5 D 0 0 schoolhouse-acorn-flush-clear-stripe-PB5-blush-pink-white-bulb-1890.jpg Acorn Flush Mount, 380-Blush Pink, Clear Glass, Three Painted Band, 200-White, Shown with Edison 1890 Era Bulb 1000 1000 73429
58321 62977 product 0 70554 A 6 C 0 0 Kao_Primary_Schoolhouse_Flush_Mount_Light_-_Barn_Light_Electric_-_Exterior_Schoolhouse_Porch_Lighting_1.jpg Kao Primary Schoolhouse Flush Mount, 100-Black, Large Opaque Glass | Photo Courtesy of The Made Shop 1500 1500 70554
60053 64875 product 0 72286 A 6 C 0 0 Round_Schoolhouse_Semi-Flush_Mount_Pendant_-_300_Dark_Green_Barn_Light_Electric_-_Vintage_Kitchen_Lighting.jpg Round Semi-Flush, 307-Emerald Green Fitter, Opaque Glass, Four Painted Band in 307-Emerald Green | Photo Courtesy of Chris Rune 1500 2559 72286
61195 64903 product 0 73428 A 6 D 0 0 schoolhouse-acorn-flush-opaque-stripe-PB5-dark-green-jadite.jpg Acorn Flush Mount, 300-Dark Green, Opaque Glass, Three Painted Band, 311-Jadite 1000 1000 73428
64292 64909 product 0 76525 A 6 C 0 0 image8-residential-interior-bathroom-lighting-Drum-Schoolhouse-Flush-Mount-Opaque-705-Navy-PB8-Four-Painted-Bands-705-Navy_-_copy.jpeg Drum Flush Mount, Opaque, 705-Navy, PB8-Four Painted Bands, 705-Navy | Photo Courtesy of Homeowner 1484 1213 76525
65272 64903 product 0 77505 A 6 C 0 0 IMG_1568-residential-interior-lighting-kitchen-sink-Acorn-Schoolhouse-Flush-Mount-Opaque-500-Buttery-Yellow-PB4-Three-Painted-Band.jpg Acorn Flush Mount, Opaque Glass, 500-Buttery Yellow, PB4-Three Painted Band 3005 3658 77505
65273 64903 product 0 77506 A 6 C 0 0 IMG_1578-residential-interior-lighting-kitchen-sink-Acorn-Schoolhouse-Flush-Mount-Opaque-500-Buttery-Yellow-PB4-Three-Painted-Band.jpg Acorn Flush Mount, Opaque Glass, 500-Buttery Yellow, PB4-Three Painted Band 3024 4032 77506
65336 64903 product 0 77569 A 6 C 0 0 IMG_1669-residential-interior-lighting-kitchen-sink-Acorn-Schoolhouse-Flush-Mount-Opaque-500-Buttery-Yellow-PB4-Three-Painted-Band.jpg Acorn Flush Mount, Opaque Glass, 500-Buttery Yellow, Three Painted Band | Photo Courtesy of Homeowner 2768 2366 77569
60054 64875 product 0 72287 A 7 C 0 0 Round_Schoolhouse_Semi_Flush_Mount_Pendant_-_Barn_Light_Electric_-_Kitchen_Lighting.jpg Round Semi-Flush, 307-Emerald Green Fitter, Opaque Glass, Four Painted Band in 307-Emerald Green | Photo Courtesy of Chris Rune 1500 2667 72287
65908 64909 product 0 78141 A 7 C 0 0 image4-residential-interior-lighting-bedroom-kid-Drum-Schoolhouse-Flush-Mount-Opaque-400-Barn-Red-PB8-Four-Painted-Band-400-Barn-Red.jpeg Drum Flush Mount, Opaque Glass, 400-Barn Red, PB4-Four Painted Bands, 400-Barn Red | Customer Submission 3024 4032 78141
67911 62977 product 0 80144 A 7 C 0 0 image_67130881-residential-interior-lighting-bathroom-Kao-Primary-Schoolhouse-Flush-Mount-Small-Opaque-480-Blush-Pink.JPG Kao Primary Schoolhouse Flush Mount, Small Opaque, 480-Blush Pink | Customer Submission 3024 4032 80144
28322 62977 product 0 40515 A 8 C 0 0 kao-schoolhouse-jadite.jpg Kao Primary Schoolhouse Flush Mount, 311-Jadite, Small Opaque Glass, Single Painted Band | Photo Courtesy of Customer 600 900 40515
60055 64875 product 0 72288 A 8 C 0 0 Round_Schoolhouse_Semi_Flush_Mount_Pendant_-_Barn_Light_Electric_-_Vintage_Inspired_Kitchen_Lighting.jpg Round Semi-Flush, 307-Emerald Green Fitter, Opaque Glass, Four Painted Band in 307-Emerald Green | Photo Courtesy of Chris Rune 1500 2481 72288
64293 64909 product 0 76526 A 8 C 0 0 image6-residential-interior-bathroom-lighting-Drum-Schoolhouse-Flush-Mount-Opaque-705-Navy-PB8-Four-Painted-Bands-705-Navy.jpeg Drum Flush Mount, Opaque, 705-Navy, PB8-Four Painted Bands, 705-Navy | Photo Courtesy of Homeowner 1329 1515 76526
60056 64909 product 0 72289 A 9 C 0 0 Drum_Schoolhouse_Semi-Flush_Mount_Light_-_Barn_Light_Electric_-_Kitchen_Lighting.jpg Drum Flush Mount, 307-Emerald Green Fitter, Opaque Glass, Four Painted Band in 307-Emerald Green | Photo Courtesy of Chris Rune 2268 4032 72289
63354 62977 product 0 75587 A 9 C 0 0 Kao_Primary_Schoolhouse_Flush_Mount_Light_-_Barn_Light_Electric_-_Flush_Mount_Pendant_Schoolhouse_Exterior_Lighting_1.jpg Kao Primary Schoolhouse Flush Mount, 100-Black, Large Opaque Glass | Photo Courtesy of The Made Shop 1500 1000 75587
55242 62977 product 0 67475 A 10 C 0 0 kao_primary_schoolhouse_flush_small_delphite_blue.jpg Kao Primary Schoolhouse Flush Mount, 715-Delphite Blue, Small Opaque Glass | Photo Courtesy of Homeowner 1500 2000 67475
67912 62977 product 0 80145 A 11 C 0 0 image_67185153-residential-interior-lighting-bathroom-Kao-Primary-Schoolhouse-Flush-Mount-Small-Opaque-480-Blush-Pink.JPG Kao Primary Schoolhouse Flush Mount, Small Opaque, 480-Blush Pink | Customer Submission 3024 4032 80145