日期:2014-05-16 浏览次数:20784 次
SELECT c1.*,u.* FROM `contents` c1 LEFT JOIN `user` u ON c1.user_id=u.id LEFT JOIN `contents` c2 ON c1.user_id=c2.user_id AND c1.id>c2.id GROUP BY c1.id,c1.user_id,c1.content HAVING COUNT(c2.id)<2