class.mysql.php : 1064 - Something is wrong in your syntax obok 'AND ogl.status = 'ACCEPT' AND ogl.type = '' AND ogl.id <> HAVING pay.pay_expire' w linii 1 SELECT ogl.id, ogl.category, ogl.title, ogl.city, ogl.forever, ogl.cost, ogl.cost_notice, ogl.for_free, pay.pay_create, pay.pay_expire FROM oglo23_announcement AS ogl LEFT JOIN oglo23_announcement_payments as pay ON ogl.ident=pay.pay_ident AND pay.pay_type='VIEW' WHERE ogl.category = AND ogl.status = 'ACCEPT' AND ogl.type = '' AND ogl.id <> HAVING pay.pay_expire>='2024-11-12' OR ogl.forever = 'TRUE' ORDER BY ogl.id > DESC, ogl.id ASC