knight1001
Technical User
Exception Details: System.Data.OleDb.OleDbException: The
I keep recieving this error, can't possibly think about why its saying it as there are no reserved words.
SELECT statement includes a reserved word or an argument name that is misspelled or missing, or the punctuation is incorrect.
Source Error:
Line 49: connectionxy.Open();
Line 50:
Line 51: readerxy = commandxy.ExecuteReader();
Line 52: if (readerxy.Read())
Line 53: {
Here is the code including the SELECT statement.
I keep recieving this error, can't possibly think about why its saying it as there are no reserved words.
SELECT statement includes a reserved word or an argument name that is misspelled or missing, or the punctuation is incorrect.
Source Error:
Line 49: connectionxy.Open();
Line 50:
Line 51: readerxy = commandxy.ExecuteReader();
Line 52: if (readerxy.Read())
Line 53: {
Here is the code including the SELECT statement.
Code:
private void ButtonFetch_Click(object sender, EventArgs e)
{
commandxy = new OleDbCommand("SELECT Cars.[Team Name], Cars.[Factory Day], Cars.[Engine Make], Cars.[Main Sponsor], FROM Cars WHERE Cars.[Car No] = @No;");
commandxy.Parameters.Add(new OleDbParameter("@No", OleDbType.Integer));
commandxy.Parameters.Add(new OleDbParameter("@No", OleDbType.Integer));
commandxy.Parameters["@No"].Value = ListCarNo.SelectedValue;
commandxy.Connection = connectionxy;
connectionxy.Open();
readerxy = commandxy.ExecuteReader();
if (readerxy.Read())