>>>We have an application which contains modules developed in VFP and VB.
>>>We have recently discovered that if a VFP module and a VB module attempt to update the same table and the same time that the index is not updated. The records created by the VB module are in the table but cannot be SELECTed.
>>>
>>>Any ideas?
>>
>>How are you accessing the VFP table from within VB (Jet, ODBC, ADO, ?)? It sounds like you're writing records into the table without having the proper index open. If you're using .IDX files, or a non-structural .CDX file, or using an older driver that does not support structural .CDX files (like the generic xBASE ODBC driver) this is the most likely scenario.
>>
>>We are using ODBC and the INTERSOLV 3.01 32 bit Foxpro 3.0 driver. In most cases the index is updated ok, it only appears to be a problem if VFP and VB update the table and the same time. We generate the primary key. The problem appears to occur if the physical sequence of the records differs to the primary key sequence.
I don't know the Intersolve ODBC driver, but the first thing I'd try would be to use another ODBC driver in place of it (Microsoft's VFP5 ODBC driver is available for download from their Web site). I'd also take a look at the mechanism used to generate primary keys, especially if based on referencing another table, in case it's an issue of ensuring that the key reference is accessed serially.