关于MySqlParameter使用的错误

搜索了半天,检查了半天,却怎么用也不对,原来问题出在sql上:

"select count(*) from checkbodyreport where GUID='?guid'

应该是:

"select count(*) from checkbodyreport where GUID=?guid

注意到差别了吗,被替换的参数一定不能用引号括起来

。。。

猜你喜欢

转载自www.cnblogs.com/mosakashaka/p/12608018.html