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 (17351,24412,4765,44745,18237,37267,44775,18446,19057,44861,18894,39676,44866,43800,45051,18172,5993,17092,45517,18719,45043,6609,22509,44875,45277,44837,6875,44836,45180,18650,17009,44878,18572,18794,44764,45561,17527,17835,45042,18301,44858,31354,45286,17601,9341,44835,18353,18688,4686,13425,14402,44856,17335,17114,17981,18286,17839,34194,44674,5388,18042,32454,44849,5259,18900,16935,18648,44640,44865,45229)
Unknown column 'np.person' in 'where clause'