Home >Backend Development >PHP Tutorial >在写php语句中sql的写法有点混

在写php语句中sql的写法有点混

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOriginal
2016-06-23 13:34:37749browse

即where和having是否可以通用


回复讨论(解决方案)

where 是删选数据表的条件
having 是删选结果集的条件

经 where 删选后,结果集就可能会很小
having 只是再做一次筛选以挑出所需数据

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