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 (17771,44866,32454,17839,44674,8753,18648,17556,5388,44762,18185,45262,6875,43800,24411,22509,45561,17981,6862,44837,19057,17278,18446,18794,24412,17527,45517,18172,44853,44855,44845,44878,44836,44851,18286,3,44867,45043,5410,44689,24438,13,17848,45180,44868,18427,18572,44685,18279,44765,44711,36472,39676,17755,17351,4686,45286,45177,18301,18996,44854,44687,24441,17703,44858,13922,13425,44531,44865,44849)
Unknown column 'np.person' in 'where clause'