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 (18688,6862,6875,24411,17237,17556,18427,45072,44685,44835,44762,30986,17981,17848,32454,17703,4686,45518,18652,34194,45286,44745,44837,43800,17839,5388,45051,3,18572,45177,44775,14622,44739,18185,18648,45180,44674,18301,5993,44878,14402,44768,45567,45262,24412,45277,45229,17601,13425,39676,44866,18237,44853,44766,17335,31354,44687,44764,30963,9341,13988,18794,44849,44845,45421,18279,44767,18900,37057,44640)
Unknown column 'np.person' in 'where clause'