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 (45286,45277,14402,44853,17351,18719,24411,6609,44865,28313,4765,37057,45421,44711,44848,18688,18237,45229,8753,45043,44835,44768,24412,44766,44878,17848,17527,44845,45177,37267,30963,4686,13988,5410,17756,16885,45567,45346,45517,30986,18794,44640,18981,19078,18996,18900,44875,19057,18286,45518,17092,44866,44775,5993,34194,17601,22509,13,44868,39676,44689,31354,18446,44837,18185,13425,30135,17278,18353,18572)
Unknown column 'np.person' in 'where clause'