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 (17904,28530,17601,18172,5388,17237,45042,16885,18688,44775,10402,44869,45229,3,5259,44863,39676,31354,17848,17981,44868,17556,18794,44894,44836,13988,24411,24412,44640,34194,44849,44853,45516,17009,44875,45180,6782,44766,43800,44768,44745,17492,45567,17278,13,17835,44878,30986,45262,17335,44856,44689,5410,22509,18286,18981,6875,14402,17756,18719,45515,44845,18894,45277,18237,44854,19057,18900,6862,45346)
Unknown column 'np.person' in 'where clause'