get() SELECT a_id,a_title,a_meta_title,a_date,a_text,a_google_type, (case when articles.a_title LIKE '%moody's%' then 1 else 0 end) + (case when articles.a_keywords LIKE '%moody's%' then 0.8 else 0 end) + (case when articles.a_text LIKE '%moody's%' then 0.6 else 0 end) + (case when autori.autor_nume LIKE '%moody's%' then 0.2 else 0 end) as weight FROM articles, autori WHERE articles.autor_id_fk=autori.autor_id AND ((articles.a_date IS NOT NULL && articles.a_date<=NOW())) AND(articles.a_title LIKE "%moody's%" OR articles.a_keywords LIKE "%moody's%" OR articles.a_text LIKE "%moody's%" OR autori.autor_nume LIKE "%moody's%" ) AND articles.a_type LIKE "FREE" ORDER BY weight DESC, articles.a_date DESC, articles.a_id DESC LIMIT 0,18
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 's%' then 1 else 0 end) + (case when articles.a_keywords LIKE '%moody's%' at line 2