I suspect your problem is that the iis user doesn't have enough permissions on the database file to run the update statement you are trying to run.
If you can give us more information such as what web server you are using, the location of the database, the type of database and the method you are using to connect to the database we can probably help more.