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,44531,18648,17009,37267,44640,17981,18279,17556,45517,22509,14622,44775,4765,6862,45229,44711,14402,39676,6609,18981,18185,3883,9341,44669,44739,44849,18353,17771,18652,44894,45346,45515,45043,44768,5259,44848,13922,44766,45518,17351,44863,17527,45516,44762,44866,17839,44869,10402,44767,18042,18650,44875,44765,31354,13,17657,44835,17601,17904,18286,17756,45051,44873,44865,44858,44685,45277,17092,45042)
Unknown column 'np.person' in 'where clause'