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 (44640,17848,44765,36472,18572,45515,44685,22509,24412,44745,45051,6609,4686,30963,18279,24411,44762,18688,5993,18900,18042,18794,4765,45277,18172,44689,3,43800,17556,17756,45286,30135,45421,39676,6862,44835,44853,45346,44687,17335,18301,45517,44894,44854,18652,18981,18648,44869,44851,18286,24441,44868,30986,44875,28530,5410,18650,44767,37057,5388,44870,17351,14402,44845,16935,44766,45561,34194,18446,45177)
Unknown column 'np.person' in 'where clause'