String sql=" delete from rizhi where data="+data;为什么总是报错,dat
来源:学生作业帮 编辑:神马作文网作业帮 分类:综合作业 时间:2024/11/23 21:40:03
String sql=" delete from rizhi where data="+data;为什么总是报错,data为varchar型.
错误提示:You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ' at line 1
错误提示:You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ' at line 1
String sql="delete from rizhi where `data`='" + data + "'";
varchar 型的值,需要用单引号包起来
再问: String sql="delete from rizhi where 'data' = '"+data+"'"; 这个没有显示错误,但数据没有被删除掉。。。
再答: 你写错了 String sql="delete from rizhi where `data`='" + data + "'"; where 后面的 data 两边不是单引号,是键盘上 数字1前面的那个键
varchar 型的值,需要用单引号包起来
再问: String sql="delete from rizhi where 'data' = '"+data+"'"; 这个没有显示错误,但数据没有被删除掉。。。
再答: 你写错了 String sql="delete from rizhi where `data`='" + data + "'"; where 后面的 data 两边不是单引号,是键盘上 数字1前面的那个键
String sql=" delete from rizhi where data="+data;为什么总是报错,dat
sql="select * from "&data&" where id="&myid&"" 在数据库中没有data 这
sql="delete from xiaolei where dalei_mz='"&dalei_mz&"'"
String sql = "select * from tb_consumer where account='" + a
MFC中data=data
string sql = "select * from user where user_name='" +t1.Text
下面的SQL语句select * from [viwBasket] where tblUser='" + (string
DELETE FROM L_DanWei WHERE dw_id = @dw_id
data
delete from 表名 where status=1什么意思
定义DATA = I am a student from China 你在任何单元格中输入 =DATA ,都会显示 I
$this->data['comment']=''; if (isset($this->session->data['c