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 = 'vi' 
WHERE 
  cscart_images_links.object_type = 'product' 
  AND cscart_images_links.type = 'M' 
  AND cscart_images_links.object_id IN (
    33702, 
    33776, 
    49809, 
    41294, 
    1484, 
    33559, 
    33560, 
    33561, 
    37120, 
    37109, 
    37110, 
    37108, 
    37112, 
    37111, 
    37117, 
    37115, 
    37114, 
    37119, 
    37116, 
    37118, 
    37093, 
    37113, 
    37096, 
    37176, 
    37181, 
    37191, 
    37196, 
    37201, 
    37206, 
    37215, 
    37220, 
    37225, 
    37230, 
    37235, 
    37240, 
    37245, 
    37250, 
    37211, 
    37212, 
    37213, 
    37214, 
    18772, 
    18771, 
    3873, 
    22987, 
    1584, 
    36762, 
    37042, 
    37040, 
    37041, 
    33724, 
    34226, 
    34243, 
    34202, 
    34203, 
    34204, 
    34205, 
    34206, 
    34207, 
    34208, 
    34209, 
    34210, 
    34211, 
    34212, 
    34213, 
    34214, 
    34215, 
    34216, 
    34217, 
    26895, 
    32569, 
    32570, 
    32571, 
    32574, 
    32577, 
    32580, 
    32583, 
    856, 
    24507, 
    45426, 
    45425, 
    45424, 
    45423, 
    45422, 
    45421, 
    45420, 
    45419, 
    45418, 
    45417, 
    45416, 
    45415, 
    45414, 
    45413, 
    45412, 
    45411, 
    45410, 
    45409, 
    45408, 
    45357, 
    23051, 
    23050, 
    26894, 
    32561, 
    32562, 
    32563, 
    32564, 
    32565, 
    49327, 
    23267, 
    49328, 
    49326, 
    47014, 
    47106, 
    47107, 
    26872, 
    27044, 
    26877, 
    27039, 
    48231, 
    48232, 
    26891, 
    32668, 
    32669, 
    32670, 
    32671, 
    32672, 
    18251, 
    18250, 
    4442, 
    26887, 
    32654, 
    32653, 
    32655, 
    32656, 
    32657
  ) 
ORDER BY 
  cscart_images_links.position, 
  cscart_images_links.pair_id

Query time 0.00362

JSON explain

{
  "query_block": {
    "select_id": 1,
    "nested_loop": [
      {
        "read_sorted_file": {
          "filesort": {
            "sort_key": "cscart_images_links.position, cscart_images_links.pair_id",
            "table": {
              "table_name": "cscart_images_links",
              "access_type": "ALL",
              "possible_keys": ["object_id"],
              "rows": 125,
              "filtered": 100,
              "attached_condition": "cscart_images_links.object_type = 'product' and cscart_images_links.`type` = 'M' and cscart_images_links.object_id in (33702,33776,49809,41294,1484,33559,33560,33561,37120,37109,37110,37108,37112,37111,37117,37115,37114,37119,37116,37118,37093,37113,37096,37176,37181,37191,37196,37201,37206,37215,37220,37225,37230,37235,37240,37245,37250,37211,37212,37213,37214,18772,18771,3873,22987,1584,36762,37042,37040,37041,33724,34226,34243,34202,34203,34204,34205,34206,34207,34208,34209,34210,34211,34212,34213,34214,34215,34216,34217,26895,32569,32570,32571,32574,32577,32580,32583,856,24507,45426,45425,45424,45423,45422,45421,45420,45419,45418,45417,45416,45415,45414,45413,45412,45411,45410,45409,45408,45357,23051,23050,26894,32561,32562,32563,32564,32565,49327,23267,49328,49326,47014,47106,47107,26872,27044,26877,27039,48231,48232,26891,32668,32669,32670,32671,32672,18251,18250,4442,26887,32654,32653,32655,32656,32657)"
            }
          }
        }
      },
      {
        "table": {
          "table_name": "cscart_images",
          "access_type": "eq_ref",
          "possible_keys": ["PRIMARY"],
          "key": "PRIMARY",
          "key_length": "4",
          "used_key_parts": ["image_id"],
          "ref": ["dev_db.cscart_images_links.detailed_id"],
          "rows": 1,
          "filtered": 100
        }
      },
      {
        "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": ["dev_db.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 = 'vi' and trigcond(cscart_images.image_id is not null))"
        }
      }
    ]
  }
}