select a.labels,group_concat(title) from article a,label l
where INSTR(concat(',',a.labels,','),concat(',',l.id,','))>0 group by labels
http://chenwei.me/p/55.html
http://richelace.blog.sohu.com/101765008.html
假设存放表B的Id的叫表A,在A表字段名为no,你是想获取表B里的名:
select b.id,b.name from A a,B b where a.no=b.id;
如果回答对您有帮助,请采纳
请记得采纳我的答案哦