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 (13,44875,14622,45180,18981,44851,45421,34194,18279,44762,24441,17114,16885,24438,4765,45516,17657,17703,30986,44869,44711,19078,44861,45043,44870,37057,44849,44854,3,45277,17335,17351,45051,13425,17755,18042,44848,44687,18427,18652,17527,44836,44764,44674,44766,43800,17835,44739,44671,10402,44884,6875,18648,45561,24411,45286,44856,18286,6862,5388,45517,18237,18900,28313,18301,44858,18794,17237,30963,45042)
Unknown column 'np.person' in 'where clause'