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 (6862,22509,44745,44855,16885,44894,24411,4765,18430,18794,44845,30986,17771,3,17114,30135,30963,44640,44870,16935,43800,44869,17981,18353,44853,37057,17756,44689,6875,32454,18650,17835,44674,18301,45277,44835,44849,24438,13922,44848,45561,44685,6609,44858,44766,17848,5259,39676,44878,45262,19078,44765,19057,44873,18185,44851,45515,8753,18719,10402,5388,45517,44863,45346,4686,17278,44856,17839,44764,18996)
Unknown column 'np.person' in 'where clause'