Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Create View with (Buffering = .T.)
Message
From
21/06/2006 10:42:39
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Title:
Create View with (Buffering = .T.)
Miscellaneous
Thread ID:
01130513
Message ID:
01130513
Views:
68
Hello,

I am using the following scenario:
OPEN DATABASE MyDBC
OPEN DATABASE ViewDBC
*
USE MyDBC!MyTable ALIAS MyTable
=CURSORSETPROP("Buffering",5,"MyTable")
*
SET DATABASE TO ViewDBC
CREATE SQL VIEW MyView AS ;
	SELECT	MyField ;
	FROM MyDBC!MyTable WITH (BUFFERING = .T.)
*
DBSETPROP("MyView","VIEW","TABLES","MyDBC!MyTable")
DBSETPROP("MyView","VIEW","SendUpdates",.T.)
DBSETPROP("MyView.MyField","FIELD","KEYFIELD",.T.)
DBSETPROP("MyView.MyField","FIELD","UPDATENAME","MyDBC!MyTable.MyField")
DBSETPROP("MyView.MyField","FIELD","UPDATABLE",.T.)
*
SET DATABASE TO MyDBC
*
Use ViewDBC!MyView ALIAS MyView IN 0
*
?MyTable.MyField && Returns 0
?MyView.MyField && Returns 0
*
REPLACE MyField WITH 1 IN MyTable
*
=REQUERY("MyView")
*
?MyTable.MyField && Returns 1
?MyView.MyField && Returns 0
I must admit that I expected the field in the view to show the same value as in the buffered table. Perhaps the Buffering=.T. in the view is ignored?

Is there a way to have the requeried view fetch the data from the buffered table?
Christian Isberner
Software Consultant
Next
Reply
Map
View

Click here to load this message in the networking platform