Home  >  Article  >  Backend Development  >  复选数据汇总有关问题

复选数据汇总有关问题

WBOY
WBOYOriginal
2016-06-13 11:21:06789browse

复选数据汇总问题
复选框,如果我想对选择的数据进行group_concat()操作,请问怎么做呢?


------解决方案--------------------
$in=implode(',',$_POST['id']); //假设复选框name为id[]<br />$sql="select id, group_concat(name) from tt where id in($in) group by id";<br />...
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Previous article:关于pscws4分词有关问题Next article:求写1SQL语句