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 (44849,13,18652,44845,44837,18301,5993,22509,4686,13425,18996,17904,37267,14402,44858,44866,17278,45042,45515,44766,18981,45421,44869,44762,17981,45051,44855,18279,44765,17351,18430,30986,18353,3883,4765,44863,44768,5388,17657,44865,44848,44884,18237,44674,31354,6782,45561,17601,18900,44689,13922,24412,44835,44894,44878,16935,44873,17703,18648,45516,3,44640,44853,18042,9341,17771,5259,44851,30963,45346)
Unknown column 'np.person' in 'where clause'