Home  >  Article  >  Database  >  Incorrectsyntaxnear's'

Incorrectsyntaxnear's'

WBOY
WBOYOriginal
2016-06-07 15:54:521266browse

出错的SQL: update address set is_mapping='A',lat=39.8123779296875,lon=-74.9393539428711,Mapping_Platform='BingA',Mapping_Return_Result='High',County='04',Municipality='0406',source_address='196 Veteran's Ave, West Berlin, NJ 08091' where a

出错的SQL:

update address set is_mapping='A',lat=39.8123779296875,lon=-74.9393539428711,Mapping_Platform='BingA',Mapping_Return_Result='High',County='04',Municipality='0406',source_address='196 Veteran's Ave, West Berlin, NJ 08091' where address_id=2481200

错误发生在:source_address='196 Veteran's Ave, West Berlin, NJ 08091' , 这个字段里面有个单引号。

解决方案:将‘替换成’’

Code:sDisplayName.Replace(“'”, “''”)

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