Yes, you could cheat with an SQL command tool and use the key fetched for the other table, but client engines are not that smart, I must add. If you can't do so, then your question is most likely not a good fit for this site. Imagine, that you'd like to update this resultset (even manually by some SQL command tool): because you didn't fetch any unique primary key. I only guess, but I don't believe that there are fetched any metadata for the WHERE clause (which is the only place where you could get the unique primary key for the Customer table).The error is "Key column information is insufficient or incorrect. The statement should be updating the 'total' field to the value of '1'.
Thank you, Daniel Daniel Hutchins Woodbridge, CA have noticed that when you use ADO in VBA, this message appears when you either update the Key field, or you don't have a key field and you update the field that VBA has decided to use to uniquely identify your records.
When I added a key field to my MS Access table, my code ran several times with an error.
I had the same issue and followed your example, but then after adding id to the select, it was working even without the final "WHERE".
You received this error: because ADO doesn't know which record should update (or refresh) because of the missing unique identifier for both tables (primary unique keys you missed to fetch).
In optimistic remote updating, the key to the complexity is that the CCE does not "own" the data it is ultimately updating.
Instead, the data is owned by some specific provider, and the CCE must submit update requests in the form of SQL commands.
You are currently viewing the BOOK: Beginning Access VBA section of the Wrox Programmer to Programmer discussions.
This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. By joining today you can post your own programming questions, respond to other developers questions, and eliminate the ads that are displayed to guests. I am getting the message "key column information is insufficient or incorrect.
ADOQuery CCBefore Edit(Data Set: TData Set); begin Save Enabled := True; end; procedure TFNew Car. Screen Shot Leaving aside the recent changes issue, on what exact line of your code do you get the "Insufficient key column" error?