精易论坛

标题: mysql添加一直失败 有大神指点下哪里错了么 [打印本页]

作者: w6039506    时间: 2020-12-17 23:37
标题: mysql添加一直失败 有大神指点下哪里错了么


作者: Patek    时间: 2020-12-17 23:42
编辑框.内容 后面再加个 单引号......
作者: w6039506    时间: 2020-12-17 23:46
Patek 发表于 2020-12-17 23:42
编辑框.内容 后面再加个 单引号......

加了没用
作者: w6039506    时间: 2020-12-17 23:47
w6039506 发表于 2020-12-17 23:46
加了没用

"insert into  `no_registration_code`  set `registration_code_no`='" + 编辑框_姓名.内容 + "'"
作者: Patek    时间: 2020-12-18 10:26
w6039506 发表于 2020-12-17 23:47
"insert into  `no_registration_code`  set `registration_code_no`='" + 编辑框_姓名.内容 + "'" ...

表名对了吗? 是 no_registration_code ?
作者: w6039506    时间: 2020-12-18 12:18
Patek 发表于 2020-12-18 10:26
表名对了吗? 是 no_registration_code ?

表名都是没问题的 直接在数据库执行命令是可以的·
作者: kamikaze    时间: 2020-12-25 19:37
"INSERT INTO `no_registration_code` (`registration_code_no`) VALUES ('"+编辑框_姓名.内容+"')+"

补充内容 (2020-12-25 19:38):

"INSERT INTO `no_registration_code` (`registration_code_no`) VALUES ('"+编辑框_姓名.内容+"')"  没有最后一个加号
作者: w6039506    时间: 2020-12-27 21:15
kamikaze 发表于 2020-12-25 19:37
"INSERT INTO `no_registration_code` (`registration_code_no`) VALUES ('"+编辑框_姓名.内容+"')+"

补充 ...

没用还是不行
作者: kamikaze    时间: 2020-12-27 21:57
w6039506 发表于 2020-12-27 21:15
没用还是不行

你确定 不是 你的表名有问题?
作者: asd0023    时间: 2022-12-1 20:41
"insert into  `no_registration_code`  set `registration_code_no`=`" + 编辑框_姓名.内容 + "`"




欢迎光临 精易论坛 (https://125.confly.eu.org/) Powered by Discuz! X3.4