SQL updates on MS Access Database: error: Operation must use an updateable query.

  • Thread starter Thread starter Neil Zanella
  • Start date Start date
N

Neil Zanella

Hello,

I am trying to update an MS access database from ASP.NET. I am using IIS on
Windows XP Pro. I can issue SELECT statements from ASP.NET using ADO.NET but
I cannot seem to be able to carry out INSERT statements. Here is the error
which I am getting:

Exception Details: System.Data.OleDb.OleDbException:
Operation must use an updateable query.

Line 67: cmd.ExecuteNonQuery();

I have found some posts where users had a similar problem and it seems that
they were able to resolve it by setting NTFS file permissions. However I am
not sure about how to go about doing this:

I wonder whether someone could please post precise instructions on how to
solve this. I have tried running inetmgr and setting them from there but
I must have done something wrong as I am still getting the same error.

Thanks a lot!!!

Neil
 
Hi Neil,

Check out ASPNET account permission to access the folder
that Access database is in. The ASPNET account might only
have permission of Read, but not permission of Write.

Hope it helps.

Elton Wang
(e-mail address removed)
 
Thank you for your reply,

What I ended up doing was I clicked on the MS Access (.mdb) file and
then under Properties -> Securities added an account called Everyone
and set permissions to "Full Control" for this account. So now I can
update the MS Access file via the ASP.NET web interface.

Regards,

Neil
 
Back
Top