SELECT
a.*,
b.option_name,
b.internal_option_name,
b.option_text,
b.description,
b.inner_hint,
b.incorrect_message,
b.comment
FROM
cscart_product_options as a
LEFT JOIN cscart_product_options_descriptions as b ON a.option_id = b.option_id
AND b.lang_code = 'ru'
WHERE
a.product_id IN (
177, 179, 180, 181, 183, 184, 185, 186,
187, 188, 189, 190, 191, 7, 11, 12, 15,
27, 28, 29, 30, 31, 32, 33, 34, 37, 38,
39, 40, 41, 42, 43, 47, 48, 49, 50, 51,
52, 53, 54, 55, 56, 57, 58, 59, 60, 62,
63, 64, 65, 67, 68, 69, 70, 71, 72, 73,
74, 75, 76
)
AND a.status = 'A'
ORDER BY
a.position