Tech
Forums
Jobs
Books
Events
Interviews
Live
More
Learn
Training
Career
Members
Videos
News
Blogs
Login
Sign Up
Ask Question
3
Reply
System.Data.SqlClient.SqlException: Incorrect syntax near '
Mohammed Shamsheer
Aug 21 2012 4:38 AM
6.9k
Reply
SqlConnection con = new SqlConnection("Data Source=APPLE;Initial Catalog=sam;Integrated Security=True");
SqlCommand cmd = new SqlCommand();
cmd.Connection = con;
con.Open();
string str1 = "DELETE * FROM AU_Delete";
cmd.CommandText = str1;
cmd.ExecuteNonQuery();
con.Close();
This is my coding for delete button it's showing error :
Exception Details:
System.Data.SqlClient.SqlException: Incorrect syntax near '*'.
what is the problem in my coding?
Upload Source Code
Select only zip and rar file.
Post
Reset
Cancel
Answers (
3
)
Next Recommended Forum
css or themes and skins..which you use in website designing and if you use css only what about validations
Asp.net Logon only allow one browser