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 (17981,44878,18794,44640,13,44765,44767,44884,18894,36472,44873,44764,44870,5993,24438,44739,45515,45517,45262,44687,44894,45180,18185,4686,18446,18996,30135,3,17492,28530,45518,44835,45286,44768,13922,13988,44669,18648,44868,44854,17237,44845,45229,31354,10402,9341,13425,17351,17848,17703,6609,17835,44863,24441,18430,44837,18900,17756,17114,5388,17092,18237,17755,44674,44711,18688,30986,44762,45042,17009)
Unknown column 'np.person' in 'where clause'