Raquel, Here it is (untested). Note that the KeyFieldList property can be more than one field, separated by commas, that uniquely identify a record. The information there, along with the tables, updatablefieldlist and updatenamelist are used in constructing the where clause of the update command. You DO NOT have to have a field specified as a primary key in a database for this to work.
DEFINE CLASS caWidgets AS CursorAdapter DataSourceType = "NATIVE" Alias = "curWidgets" Tables = "Widgets" KeyFieldList = "code" SelectCmd = "select code, descrip from widgets" UpdatableFieldList = "code, descrip" UpdateNameList = code widgets.code, descrip widgets.descrip" SendUpdates = .T. WhereType = 3 && DB_KEYANDMODIFIED BufferModeOverride = 5 && Optimistic Table Buffering ENDDEFINE Be sure you have SET MULTILOCKS ON. That should get you most of the way there. David Stevenson -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Rafael Copquin Sent: Wednesday, December 06, 2006 11:28 AM To: [EMAIL PROTECTED] Subject: cursor adapters on free tables I inherited an app written in VFP6 which I am trying to convert to VFP9. This app is full of updatable views, on free tables or bounded tables with no primary keys. I am finding it impossible to create cursor adapters (either in the CA builder or in code) for any of these tables. Questions: Is it possible to create updatable cursor adapters for free tables or bounded tables with no primary keys? If so, how? please show code to create an updatable CA for this free table: widgets.dbf code C(4) && alfanumeric field descrip C(30) indexes on code and descrip, regular type TIA Rafael Copquin --- StripMime Report -- processed MIME parts --- multipart/alternative text/plain (text body -- kept) text/html --- [excessive quoting removed by server] _______________________________________________ Post Messages to: [email protected] Subscription Maintenance: http://leafe.com/mailman/listinfo/profox OT-free version of this list: http://leafe.com/mailman/listinfo/profoxtech ** All postings, unless explicitly stated otherwise, are the opinions of the author, and do not constitute legal or medical advice. This statement is added to the messages for those lawyers who are too stupid to see the obvious.

