Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Update Conflict
Message
 
À
26/05/1998 10:43:35
Information générale
Forum:
Visual FoxPro
Catégorie:
Problèmes
Titre:
Divers
Thread ID:
00101907
Message ID:
00101915
Vues:
29
UPDATE CONFLICT errors occur when user A edits a record, and another user B has changed the data in that same record before user A issues the TABLEUPDATE.

You may want to create a generic method ("m_Close") that is called by the Destroy method, Query unload method (I've never tested if the QueryUnload call Destroy, but I will now) and any other "exit" type buttons and this "close" method would handle reverting of updating data as needed. It would be within this method that you could trap for table update errors.

With table update errors you could use: TABLEUPDATE (.T.,.T.) where the last update wins or use REFRESH to refresh the data from the underlying table and allow the user to re-edit the fields that have changed, or make the user tablerevert and then make them access the record again.
===============
>>I'm working on a VFP 5.0 multi-user application. It's using optimistic table buffering. On occasion a user will get an UPDATE CONFLICT error message when closing a screen. I've been able to duplicate the error, but I'm not sure how to solve the problem. It doesn't generate the error on the TABLEUPDATE() command. It happens when you try to close a screen. It seems to have a problem closing a table in the data environment.
>>
>>
>>Any suggestions at what I should be looking at?
>>
>>Maria Arendt
>
>You could try to issue TABLEUPDATE() or TABLEREVERT() (depending on form's functionality) in Form.Destroy event.
I would give my left arm to be ambidextrous!
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform