SELECT * FROM strony A, lang_0 B, lang_1 C WHERE C.ht_1='oferta' AND A.id_all=B.id AND C.view_1='on' AND C.id_all=B.id LIMIT 1