UCZELNIA NIECZYNNA
data dodania:
SELECT link, t1.id as id, id_kat, img_list, usuniety, data_dod, data_ed, tytul, aliasy_id, zajawka, tresc, aktywny, meta_tytul, sl_klucz, a.nazwa as alias FROM blog_artykuly t1 left outer join blog_artykuly_lang as t2 on t1.id = t2.parent_id left outer join aliasy a on t2.aliasy_id = a.id where (t2.lang_id = 1 or t2.lang_id is NULL) and usuniety = 'N' and id_kat = and data_dod < "2022-12-20 00:00:00" and aktywny = "Y" order by data_dod desc limit 0, 1You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'and data_dod > "2022-12-20 00:00:00" and aktywny = "Y" order by data_dod asc lim' at line 2
SELECT link, t1.id as id, id_kat, img_list, usuniety, data_dod, data_ed, tytul, aliasy_id, zajawka, tresc, aktywny, meta_tytul, sl_klucz, a.nazwa as alias FROM blog_artykuly t1 left outer join blog_artykuly_lang as t2 on t1.id = t2.parent_id left outer join aliasy a on t2.aliasy_id = a.id where (t2.lang_id = 1 or t2.lang_id is NULL) and usuniety = 'N' and id_kat = and data_dod > "2022-12-20 00:00:00" and aktywny = "Y" order by data_dod asc limit 0, 1