Home >Backend Development >PHP Tutorial >group by和where的用法解决方法

group by和where的用法解决方法

WBOY
WBOYOriginal
2016-06-13 10:06:101066browse

group by和where的用法
select * from peizhi where tag=$row[tag] group by brand

这样写是错的。实现的是把以tag为条件把相同里面brand信息给取出来,并且是通过group by的方式取出来brand

------解决方案--------------------
select * from peizhi where tag=$row['tag'] group by brand

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