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 (45177,44674,17237,18279,30135,17848,44766,18301,44848,9341,18894,44711,43800,45072,18996,18688,17114,45229,4686,44863,44835,44531,6782,6875,31354,13,17601,44767,17756,44868,45567,3883,44856,45277,19078,17556,44853,44689,45518,44875,17278,13425,17335,18430,44764,44762,44873,36472,24438,3,19057,17657,22509,44669,37267,45180,8753,17492,30986,44745,44851,18719,18446,28313,45262,17009,24412,18652,44869,44867)
Unknown column 'np.person' in 'where clause'