Hi, I am having a problem with ADO.Net and ASP.Net, I didn't post this in the ASP.Net forum because eventhough I am using ASP.Net, the problem seems to be with ADO.Net.
Anyway the code:
{
strSQL = "UPDATE Clients SET Password = '" + newpass + "'" +
" WHERE Email='" + User.Identity.Name + "'";;
dbCon = new OleDbConnection(strCon);
dbCon.Open();
dbAdapter = new OleDbDataAdapter();
dbCom = new OleDbCommand(strSQL,dbCon);
int x= dbCom.ExecuteNonQuery();
//...code continues
Everytime i execute this, I get an exception thrown message: "Syntax error in UPDATE statement."
I tried this same query in MS Access and it works fine (i am using an Access db).
I have no clue what the error means :sad: I don't think its the SQL statement. I thought it might be the OleDbCommand
not having the capability but OleDbDataAdapter.UpdateCommand
is also OleDbCommand
so that can't be it.
Thanks in advance.