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 (18237,10402,17527,18353,45043,24412,44766,30963,44884,18650,44851,19078,18794,44894,36472,32454,3883,37057,19057,17835,24411,44745,18648,44873,14402,17601,45277,5410,17848,44865,18446,44837,5388,14622,18996,18981,17904,6609,18279,8753,44768,24441,44878,44863,45286,22509,18719,18042,31354,45515,18688,44870,45042,44848,44853,44711,17981,44854,18301,44764,30986,16935,17351,6782,44845,45051,28313,17009,17114,18900)
Unknown column 'np.person' in 'where clause'