OleDbConnection conn = new OleDbConnection(); conn.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=|DataDirectory|db1.mdb"; OleDbCommand comm = new OleDbCommand(); conn.Open(); comm.Connection = conn;
comm.CommandText = "DELETE FROM position WHERE 岗位名称 = 'a ' ";
conn.Close();
}
大家帮我看下是什么原因!感谢
------解决方案-------------------- comm.CommandText = "DELETE FROM position WHERE 岗位名称 = 'a ' "; 后添加comm.ExcuteNonQuery(); 没执行当然不成功
------解决方案-------------------- 加上 OleDbCommand.ExecuteNonQuery(); 不执行怎么有效果
------解决方案--------------------