0
錯誤:: System.Data.SqlClient.SqlException: '='附近的語法不正確。更新數據庫中的錯誤
源代碼:
cn.Open();
Line 27: cmd = new SqlCommand("updat product set status ='" + s + "'", cn);
Line 28: cmd.ExecuteNonQuery();
Line 29: cn.Close();
Line 30: }
+1所有優點! – 2011-05-02 17:15:30
我也是+1。當之無愧,特別是如果第二點中多餘的撇號是偶然的:-) – Malice 2011-08-25 08:33:29