Column control datagrid information insufficient key refreshing updating
I get the error "Insufficient Key Column Information for Updating or Refreshing". I am prepared to actually change the data under the covers by writing extra code to do that, but I need to be able to have the user change data on the form and then when they want to change records, I want to update the table data with their changes and then move to the next record. I next decided to isolate the problem down to the smallest number of fields possible. I could either leave out the reference to the foreign key in the SELECT section of my SQL statement, like so: SELECT Table1. After playing with cursor settings for awhile, I discovered it wasn't a cursor problem. Sub Description FROM Table1 INNER JOIN Table2 ON Table1. Item ID; I was able to eliminate the problem in two different ways. I did expect some complexity because the SQL has some joins in it with tables/fields that have a one to many relationship with some fields in my adodc record, but I thought I could trap and handle the error. What I discovered is that the problem was occurring because the foreign key in my many table had the same name as the primary key in my one table (a common practice). I next decided to isolate the problem down to the smallest number of fields possible. I could either leave out the reference to the foreign key in the SELECT section of my SQL statement, like so: SELECT Table1. The code is a bit long but I will email it to those who are interested.A work around or solution would be greatly appreciated. Now I get error Runtime error 545: Unable to bind to field or datamember: 'First Name on the statement "First Name. When I took back out the line from the SELECT statement about the tbl Child ID, tbl*.*ID andtbl Address.Basic Info: My SQL version 5.0.16, Windows XP Professional SP2, Visual Basic 6.0 I am trying to migrate an Access db to My SQL and have encountered the following problems on code that worked fine with Access in VB6 using the Data Dynamics Sharp Grid control but not with My SQL: updating a record gives the error: [Microsoft Cursor Engine] insufficient key column information for updating or refreshing even when the ADO recordset contains no duplicates and the primary key.An additional problem is that sometimes the new records simply disappear with no error message.
Will any one please help me to solve this problem as soon as possible.
However the changes made in the Text Boxes are no longer saved to the database during update.