"Operation must use an updateable query" win7 64bit

Tenzen

Member
Joined
Aug 18, 2010
Messages
16
Programming Experience
3-5
I cannot save to database because of this:

"Operation must use an updateable query"

I think it is because I changed XP to Win 7 64bit. How to fix that? It's permissions issue or can I fix it in Visual Studio?
 
I cannot save to database because of this:

"Operation must use an updateable query"
No, you cannot save data to the database because your code is wrong, and that error message is trying to tell you what the problem is. I would say that you're either calling ExecuteNonQuery on a DbCommand or Update on a DataAdapter and you have a SELECT statement in the SQL code. You haven't told us anything about the code that throws the exception though, so that's is only conjecture.
 
the code was good and it worked until... maybe until I update DataSet?

VB.NET:
Me.Validate()
Me.WynikiBindingSource.EndEdit()
Me.TableAdapterManager.UpdateAll(Me.DmwbdDataSet)
after that I get an error. It's from the save button.

Ok. but now it's something wrong with the code because save button desapired from BindingNavigator and I cannot restore it.

I don't use SQLConnection. Just standard Access database
VB.NET:
connectionString="Provider=Microsoft.ACE.OLEDB.12.0;[..]

In standard query "Fill" There is SELECT in CommandText. But it worked before
 
Ah, Ace 12.. in the project's properties set it to compile for x86 only & that'll allow the ace 12 driver to work on x64 win7
 
That's curious. I would have thought that the error message would be different for that. It does highlight the need to provide the full story though. Telling us what you're doing without what happens or vice versa generally means that we have to guess or assume and can often lead to incorrect or irrelevant solutions.
 
The SelectCommand is irrelevant. It's the DeleteCommand, InsertCommand and UpdateCommand that are of interest because they are the ones that are executed when you call Update. Let's see the SQL code and the entire connection string.
 
DeleteCommand, InsertCommand, UpdateCommand and connection string are correct. have not been changed since the time when everything worked. In addition, I created a new project on a fast where these parameters are the same and everything works.

I changed the system to 32bit and the problem is not resolved...

The problem is that I do not know what I did. I had not noticed the problem right away...

----------------------
I installed my database to Program Files. There was no problem with permission on Windows XP but there is on Windows 7

I have added manually permission to the installation folder. I think now how to add it automatically.
 
Last edited:
Back
Top