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 (44865,6862,45421,17009,10402,43800,45567,44884,44875,19057,45042,18446,17527,45277,44766,4686,28530,18650,17848,17904,44858,44531,16935,44851,45346,18042,18894,45180,24411,17601,44849,9341,45561,5388,5993,44640,44845,44764,18353,13,44669,45517,3,45515,18794,44767,18688,30963,44853,44671,44861,17556,5410,18172,44674,45518,45516,30135,17278,44762,44689,44687,24441,3883,37267,22509,18286,17755,39676,14622)
Unknown column 'np.person' in 'where clause'