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 (17237,44863,30135,44768,44671,24411,17278,3,45072,16935,45516,24412,44674,45286,45180,13988,45421,18286,17657,17335,17556,44685,44865,39676,44884,5993,43800,14622,45262,37267,45517,44669,44689,17492,17835,44870,44867,13922,44711,44764,17848,44531,17527,17755,45042,18688,44854,44858,31354,6609,45518,44849,3883,32454,44845,6862,13,44869,44875,18894,30963,18648,44640,44873,18430,18446,22509,17904,18981,17092)
Unknown column 'np.person' in 'where clause'