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 (45421,44640,44856,17839,18794,5993,45516,18353,13922,5388,4765,17492,44762,44766,44765,18648,22509,44739,3883,45051,44687,17351,24412,17771,45177,30135,44674,18652,30986,44775,18430,45043,44669,45277,24441,44837,44884,44854,18237,17278,44867,44768,37057,45180,6875,44866,44861,6782,44870,18688,44849,17237,31354,44835,17601,45229,30963,17703,44845,44671,32454,13,44894,18996,18981,44764,19057,45346,5259,45518)
Unknown column 'np.person' in 'where clause'