TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Nel
NA
716
1.1m
Missing semicolon (;) at end of SQL statement
Oct 19 2011 4:38 AM
Hello,
I have delete function and it doesn't function. I got this error:
"Missing semicolon (;) at end of SQL statement." even though I have a semicolon sign at the end of that statement.
Here is my code:
try
{
OleDbCommand commandbrisi = new OleDbCommand();
commandbrisi.CommandText = "Delete from Kazneti where Imeprezime = ? and Adresa = ? order by Rbr asc";
commandbrisi.Parameters.AddWithValue("@imeprez", txtImePrez.Text);
commandbrisi.Parameters.AddWithValue("@adresa", txtAdresa.Text);
commandbrisi.Connection = conn;
conn.Open();
OleDbDataAdapter oleDBDataAdapter1 = new OleDbDataAdapter(new OleDbCommand("Update * from Kazneti", conn));
commandbrisi.ExecuteNonQuery();//here is the error
_dataset.Clear();
oleDBDataAdapter1.Fill(_dataset, "Kazneti");
}
finally
{
conn.Close();
}
Reply
Answers (
6
)
File Management in ASP.NET C#
Dynamically generate Textbox in Repeater control and i have to validate