G
Guest
Hi,
I have a C# application with MS access 2003 as DB for password protection.
The DB has two tables: one is Logins, the other Visits.
When I do the reading as below:
SELECT Password FROM Logins WHERE Username ='dale'
it is a success.
INSERT INTO Visits (Email,LoginDate,ReferPage,LoginOK,LoginPass,IP) VALUES
('dale',#8/13/2005 11:46:41
AM#,'/passwordProtectCSharp/privatePage.aspx',1,'dale1','127.0.0.1')
it always gives me an exception as below:
Operation must use an updatable query.
The codes are:
try
{
// write the visit log entry
dbConn = new OleDbConnection(sConn);
dbConn.Open();
dbCmd = new OleDbCommand(sSQL, dbConn);
dbCmd.ExecuteNonQuery();
}
catch (Exception e)
{
Debug.WriteLine(e.Message);
}
when I write the DB as below:
I want to run the "insert" in MS access separately for testing, can not find
a way to do so. Any suggestions are welcome. -Dale
I have a C# application with MS access 2003 as DB for password protection.
The DB has two tables: one is Logins, the other Visits.
When I do the reading as below:
SELECT Password FROM Logins WHERE Username ='dale'
it is a success.
INSERT INTO Visits (Email,LoginDate,ReferPage,LoginOK,LoginPass,IP) VALUES
('dale',#8/13/2005 11:46:41
AM#,'/passwordProtectCSharp/privatePage.aspx',1,'dale1','127.0.0.1')
it always gives me an exception as below:
Operation must use an updatable query.
The codes are:
try
{
// write the visit log entry
dbConn = new OleDbConnection(sConn);
dbConn.Open();
dbCmd = new OleDbCommand(sSQL, dbConn);
dbCmd.ExecuteNonQuery();
}
catch (Exception e)
{
Debug.WriteLine(e.Message);
}
when I write the DB as below:
I want to run the "insert" in MS access separately for testing, can not find
a way to do so. Any suggestions are welcome. -Dale