SELECT 
  cscart_images.*, 
  cscart_images_links.*, 
  cscart_common_descriptions.description AS alt, 
  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 = 'ru' 
WHERE 
  cscart_images_links.object_type = 'product' 
  AND cscart_images_links.type = 'M' 
  AND cscart_images_links.object_id IN (
    51348, 121, 51345, 119, 141, 23, 4, 142, 
    51344, 120, 62, 108, 107, 51294, 51293, 
    51292, 51291, 51290, 94, 51289, 51288, 
    51287, 51286, 51285, 51284, 51283, 
    8, 86, 54, 51313, 51312, 51314, 51311, 
    51310, 10, 51182, 51181, 51180, 51179, 
    51178, 51177, 93
  ) 
ORDER BY 
  cscart_images_links.position, 
  cscart_images_links.pair_id

Query time 0.00254

JSON explain

{
  "query_block": {
    "select_id": 1,
    "cost_info": {
      "query_cost": "111.56"
    },
    "ordering_operation": {
      "using_filesort": true,
      "cost_info": {
        "sort_cost": "47.00"
      },
      "nested_loop": [
        {
          "table": {
            "table_name": "cscart_images_links",
            "access_type": "range",
            "possible_keys": [
              "object_id"
            ],
            "key": "object_id",
            "used_key_parts": [
              "object_id",
              "object_type",
              "type"
            ],
            "key_length": "81",
            "rows_examined_per_scan": 47,
            "rows_produced_per_join": 47,
            "filtered": "100.00",
            "index_condition": "((`test_uchur_k`.`cscart_images_links`.`object_type` = 'product') and (`test_uchur_k`.`cscart_images_links`.`type` = 'M') and (`test_uchur_k`.`cscart_images_links`.`object_id` in (51348,121,51345,119,141,23,4,142,51344,120,62,108,107,51294,51293,51292,51291,51290,94,51289,51288,51287,51286,51285,51284,51283,8,86,54,51313,51312,51314,51311,51310,10,51182,51181,51180,51179,51178,51177,93)))",
            "cost_info": {
              "read_cost": "26.96",
              "eval_cost": "4.70",
              "prefix_cost": "31.66",
              "data_read_per_join": "4K"
            },
            "used_columns": [
              "pair_id",
              "object_id",
              "object_type",
              "image_id",
              "detailed_id",
              "type",
              "position"
            ]
          }
        },
        {
          "table": {
            "table_name": "cscart_images",
            "access_type": "eq_ref",
            "possible_keys": [
              "PRIMARY"
            ],
            "key": "PRIMARY",
            "used_key_parts": [
              "image_id"
            ],
            "key_length": "4",
            "ref": [
              "test_uchur_k.cscart_images_links.detailed_id"
            ],
            "rows_examined_per_scan": 1,
            "rows_produced_per_join": 47,
            "filtered": "100.00",
            "cost_info": {
              "read_cost": "11.75",
              "eval_cost": "4.70",
              "prefix_cost": "48.11",
              "data_read_per_join": "36K"
            },
            "used_columns": [
              "image_id",
              "image_path",
              "image_x",
              "image_y",
              "is_high_res",
              "transparent"
            ]
          }
        },
        {
          "table": {
            "table_name": "cscart_common_descriptions",
            "access_type": "eq_ref",
            "possible_keys": [
              "PRIMARY"
            ],
            "key": "PRIMARY",
            "used_key_parts": [
              "object_id",
              "lang_code",
              "object_holder"
            ],
            "key_length": "108",
            "ref": [
              "test_uchur_k.cscart_images.image_id",
              "const",
              "const"
            ],
            "rows_examined_per_scan": 1,
            "rows_produced_per_join": 47,
            "filtered": "100.00",
            "cost_info": {
              "read_cost": "11.75",
              "eval_cost": "4.70",
              "prefix_cost": "64.56",
              "data_read_per_join": "27K"
            },
            "used_columns": [
              "object_id",
              "description",
              "lang_code",
              "object_holder"
            ]
          }
        }
      ]
    }
  }
}

Result

image_id image_path image_x image_y is_high_res transparent pair_id object_id object_type detailed_id type position alt images_image_id
0 kepka_uchur_active_cv_beige_220_kepkauchuractivecvbeige.png 1000 1400 N N 220 10 product 8818 M 0 8818
0 kepka_uchur_alpha_cv_chernyy_232_kepkauchuralphacvchernyy.png 1000 1400 N N 232 142 product 8830 M 0 8830
0 kepka_uchur_everyday_mesh_cv_black_248_kepkauchureverydaymeshcvblack.jpg 1000 1400 N N 248 62 product 8846 M 0 8846
0 kepka_uchur_hex_s_patchem_cv_chernyy_254_kepkauchurhexspatchemcvchernyy.png 1000 1400 N N 254 141 product 8852 M 0 8852
0 kepka_uchur_logo_mesh_cap_cv_olive_265_kepkauchurlogomeshcapcvolive.png 1000 1400 N N 265 23 product 8863 M 0 8863
0 kepka_uchur_round_patch_logo_grey_cv_chernyy_s_setkoy_62_1880_kepkauchurroundpatchlogogreycvchernyyssetkoy.png 1000 1400 N N 323 121 product 8921 M 0 8921
0 kepka_uchur_round_patch_cv_chernyy_s_setkoy_332_kepkauchurroundpatchcvchernyyssetkoy.png 800 1000 N N 332 4 product 8930 M 0 8930
0 kepka_uchur_rubber_patch_cv_chernyy_bez_setki_60_1873_kepkauchurrubberpatchcvchernyybezsetki.png 1000 1400 N N 345 119 product 8943 M 0 8943
0 longsliv_uchur_active_cv_taas_ru_1776_longslivuchuractivecvtaas.png 1000 1400 N N 566 94 product 9164 M 0 9164
0 panama_letnyaya_uchur_adventure_hat_cv_seryy_589_panamaletnyayauchuradventurehatcvseryy.png 1000 1400 N N 589 107 product 9187 M 0 9187
0 panama_letnyaya_uchur_adventure_hat_cv_chernyy_593_panamaletnyayauchuradventurehatcvchernyy.png 1000 1400 N N 593 108 product 9191 M 0 9191
0 perchatki_uchur_hunter_lt_cv_taas_597_perchatkiuchurhunterltcvtaas.jpg 4160 5536 N N 597 86 product 9195 M 0 9195
0 tolstovka_uchur_hoodie_wind_cv_saas_l_ru_1530_tolstovkauchurhoodiewindcvsaas.png 1000 1400 N N 886 54 product 9484 M 0 9484
0 futbolka_uchur_bear_black_t_shirt_3xl_ru_1272_futbolkauchurbearblacktshirt.png 1000 1400 N N 911 8 product 9509 M 0 9509
0 shtany_uchur_all_weather_pants_lite_cv_chernyy_ru_1740_shtanyuchurallweatherpantslitecvchernyy.png 1000 1400 N N 1080 93 product 9678 M 0 9678
0 kepka_uchur_rubber_patch_cv_chernyy_s_setkoy_62_1875_kepkauchurrubberpatchcvchernyyssetkoy.png 1000 1400 N N 1874 120 product 9818 M 0 9818
0 shtany_uchur_all_weather_pants_lite_cv_chernyy_ru_1740_shtanyuchurallweatherpantslitecvchernyy.png 1000 1400 N N 6723 51177 product 9678 M 0 9678
0 shtany_uchur_all_weather_pants_lite_cv_chernyy_ru_1740_shtanyuchurallweatherpantslitecvchernyy.png 1000 1400 N N 6731 51178 product 9678 M 0 9678
0 shtany_uchur_all_weather_pants_lite_cv_chernyy_ru_1740_shtanyuchurallweatherpantslitecvchernyy.png 1000 1400 N N 6739 51179 product 9678 M 0 9678
0 shtany_uchur_all_weather_pants_lite_cv_chernyy_ru_1740_shtanyuchurallweatherpantslitecvchernyy.png 1000 1400 N N 6747 51180 product 9678 M 0 9678
0 shtany_uchur_all_weather_pants_lite_cv_chernyy_ru_1740_shtanyuchurallweatherpantslitecvchernyy.png 1000 1400 N N 6755 51181 product 9678 M 0 9678
0 shtany_uchur_all_weather_pants_lite_cv_chernyy_ru_1740_shtanyuchurallweatherpantslitecvchernyy.png 1000 1400 N N 6763 51182 product 9678 M 0 9678
0 futbolka_uchur_bear_black_t_shirt_3xl_ru_1272_futbolkauchurbearblacktshirt.png 1000 1400 N N 7616 51283 product 9509 M 0 9509
0 futbolka_uchur_bear_black_t_shirt_3xl_ru_1272_futbolkauchurbearblacktshirt.png 1000 1400 N N 7629 51284 product 9509 M 0 9509
0 futbolka_uchur_bear_black_t_shirt_3xl_ru_1272_futbolkauchurbearblacktshirt.png 1000 1400 N N 7642 51285 product 9509 M 0 9509
0 futbolka_uchur_bear_black_t_shirt_3xl_ru_1272_futbolkauchurbearblacktshirt.png 1000 1400 N N 7655 51286 product 9509 M 0 9509
0 futbolka_uchur_bear_black_t_shirt_3xl_ru_1272_futbolkauchurbearblacktshirt.png 1000 1400 N N 7668 51287 product 9509 M 0 9509
0 futbolka_uchur_bear_black_t_shirt_3xl_ru_1272_futbolkauchurbearblacktshirt.png 1000 1400 N N 7681 51288 product 9509 M 0 9509
0 futbolka_uchur_bear_black_t_shirt_3xl_ru_1272_futbolkauchurbearblacktshirt.png 1000 1400 N N 7694 51289 product 9509 M 0 9509
0 longsliv_uchur_active_cv_taas_ru_1776_longslivuchuractivecvtaas.png 1000 1400 N N 7707 51290 product 9164 M 0 9164
0 longsliv_uchur_active_cv_taas_ru_1776_longslivuchuractivecvtaas.png 1000 1400 N N 7720 51291 product 9164 M 0 9164
0 longsliv_uchur_active_cv_taas_ru_1776_longslivuchuractivecvtaas.png 1000 1400 N N 7733 51292 product 9164 M 0 9164
0 longsliv_uchur_active_cv_taas_ru_1776_longslivuchuractivecvtaas.png 1000 1400 N N 7746 51293 product 9164 M 0 9164
0 longsliv_uchur_active_cv_taas_ru_1776_longslivuchuractivecvtaas.png 1000 1400 N N 7759 51294 product 9164 M 0 9164
0 tolstovka_uchur_hoodie_wind_cv_saas_l_ru_1530_tolstovkauchurhoodiewindcvsaas.png 1000 1400 N N 7950 51310 product 9484 M 0 9484
0 tolstovka_uchur_hoodie_wind_cv_saas_l_ru_1530_tolstovkauchurhoodiewindcvsaas.png 1000 1400 N N 7958 51311 product 9484 M 0 9484
0 tolstovka_uchur_hoodie_wind_cv_saas_l_ru_1530_tolstovkauchurhoodiewindcvsaas.png 1000 1400 N N 7966 51312 product 9484 M 0 9484
0 tolstovka_uchur_hoodie_wind_cv_saas_l_ru_1530_tolstovkauchurhoodiewindcvsaas.png 1000 1400 N N 7974 51313 product 9484 M 0 9484
0 tolstovka_uchur_hoodie_wind_cv_saas_l_ru_1530_tolstovkauchurhoodiewindcvsaas.png 1000 1400 N N 7982 51314 product 9484 M 0 9484
0 kepka_uchur_rubber_patch_cv_chernyy_s_setkoy_62_1875_kepkauchurrubberpatchcvchernyyssetkoy.png 1000 1400 N N 8888 51344 product 9818 M 0 9818
0 kepka_uchur_rubber_patch_cv_chernyy_bez_setki_60_1873_kepkauchurrubberpatchcvchernyybezsetki.png 1000 1400 N N 8898 51345 product 8943 M 0 8943
0 kepka_uchur_round_patch_logo_grey_cv_chernyy_s_setkoy_62_1880_kepkauchurroundpatchlogogreycvchernyyssetkoy.png 1000 1400 N N 8927 51348 product 8921 M 0 8921