Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to control view updates
Message
From
26/11/2002 16:19:51
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
 
 
To
26/11/2002 11:14:50
Victor Verheij
International Film Festival Rotterdam
Rotterdam, Netherlands
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00726867
Message ID:
00727303
Views:
18
>I think I understand it a bit better now.
>
>I thougt that tablerevert() could be used to revert changes made to the base table but this is not the case. I also thought that i could revert changes to the view after i had allready did a tableupate().
>
>How I understand things now is:
>1) Tablerevert() has only effect on the view, only when a tableupdate() has not yet occured.

I agree.

>2) Use cursorsetprop('buffering',5) to set tablebuffering to optimistic table buffering, to avoid records being automatically updated.

Yes; but in principle you can also check that there are no pending changes before changing to another record. This would be part of your form class. Also, note that there are some restrictions when using table buffering - for instance, you can't create temporary indices, or transactions.

>3) Tableupdate() commits changes to the VIEW and makes these changes "permanent" and "forces" these changes back into the basetable.

Yes.

>4) The cursorsetprop('buffering',5) only applies to the view.

Yes. In principle, you could also buffer the underlying table (you would have to do this separately), but I don't see the point to that. That would require TableUpdate()-ing the underlying table as well, I think.

>5) After the view is opened, changing the sendupdates property with "dbsetprop('myview',view','sendupdates',.t.)" doesn't have any effect within the current datasession.

I don't know about this one. I only work with tables or views created in the view designer, and the only property I need to set is CursorSetProp("Buffering").

Hilmar.
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform