Error in query: SELECT DISTINCT(np.person) AS person, p.first_name, p.last_name, nx.id AS news_id FROM news_person AS np, person AS p, news_category AS nc LEFT JOIN news AS nx ON nx.id = (SELECT ny.id FROM news AS ny, news_person AS nyp, news_category AS nyc WHERE ny.id = nyc.news AND nyc.category = 310 AND nyp.person = np.person AND nyc.news = ny.id AND nyp.news = ny.id AND ny.entry_active = 't' ORDER BY entry_date DESC LIMIT 0, 1) WHERE np.person = p.id AND nc.category = 310 AND nc.news = np.news AND np.person = p.id AND p.id IN (18237,17278,17981,44687,4765,18650,37057,45517,17335,44766,17492,6782,24441,17848,44762,44854,44865,3,44765,44875,13425,36472,18446,18900,44863,44835,44640,3883,16885,28530,30135,17703,45262,6875,9341,37267,18794,14402,17351,44861,45043,45346,45229,44869,24438,44894,44711,5259,44870,5410,44669,45518,13988,44868,6609,22509,17835,34194,17114,18301,44866,28313,39676,18427,24411,45277,17756,17839,43800,19057)
Unknown column 'np.person' in 'where clause'