Home >Backend Development >PHP Tutorial >请问数据库字段是整型 SQL里面变量用单引号可以吗?

请问数据库字段是整型 SQL里面变量用单引号可以吗?

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOriginal
2016-06-23 14:05:341687browse

请问数据库字段是整型, 添加的SQL语句里面变量用单引号可以吗?


回复讨论(解决方案)

可以!
你试一下不就知道了

如果字段是整型的话,SQL里面的变量可以加单引号或者不加,其他情况必须得加单引号···

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