Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Updating a view problem
Message
De
02/09/2003 09:02:39
Mike Sue-Ping
Cambridge, Ontario, Canada
 
 
À
02/09/2003 00:07:22
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
00824703
Message ID:
00825265
Vues:
33
Hi Elmer,

Thank you for clarifying something I was begining to suspect about VFP views and their inability to "refresh automatically" when a stored procedure changed a field in it.

How do I "requery the view after tableupdate" if it is in the form's dataenvironment?

Also, someone mentioned to me that an ADO recordset can be bound to the underlying database so that any changes can be reflected in the recordset. Do you know if this is true and if so, how? Is it related to the CursorAdaptor in VFP8?

Thanks for the feedback.

Regards,

Mike



>Mike,
>
>If your stored procedure is updating the underlying tables and returns .t. or .f. if successful or not, probably your only 2 options would be to calculate the area value in your form and replace the area field in the view prior to tableupdate(), OR requery the view after tableupdate. A view is a buffered snapshot of the underlying data at the time that the view is opened. You can make changes in the view and do tableupdate to save your edits, but you will not see any changes that are done by other users or by any update trigger or stored procedure unless you requery the view. Requery may be a performance hit, depending on how many records in the view.
>
>HTH
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform