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 (45051,45180,45515,18172,44671,45286,45561,44867,18900,18572,44868,18427,18279,17839,5388,45567,44531,44858,18353,45072,16885,31354,44764,17092,30986,18650,17601,18794,44875,44869,3,24441,17556,17981,44853,18996,18286,8753,44768,4765,4686,30963,5993,18894,44873,43800,45229,17835,18042,17756,13,45277,44711,5259,44849,17848,19057,44765,44674,44767,24438,24411,44762,6782,17755,17335,44745,44865,18446,39676)
Unknown column 'np.person' in 'where clause'