Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Tableupdate()
Message
De
27/09/1999 18:27:59
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Titre:
Divers
Thread ID:
00269667
Message ID:
00269685
Vues:
24
Hi Paul,

The whole idea of the view is that it's created ONCE and used, like a table, as needed. There should be no good reason to recreate your views every time you run the application.

Your workaround is to create your views, use DBSETPROP() ONCE to set the view properties the way you want them (or modify them at runtime with CURSORSETPROP or using the DataEnvironment BufferModeOverride) and be done with it.


>i have come across a problem and i'm not quite sure if it's mine or fox.
>
>some details ;
>
>when i run my app, i have code to create all the views that the app needs.
>
>the problem ;
>
>when i create the views at the start of the app, none of the tableupdate() calls work. if i don't create the views and simply assume that they are there and open them, then the tableupdate() calls work.
>
>i have spent many hours tracking this down and have can reproduce this with a small program.
>
>have you run into any similar issues? if so, how do i work around this within my app?
>
>thanks in advance for your assistance,
>
>pbd
>
>ps: here is the code just in case
>
>function broke
>
>close databases all
>open database payroll
>
>CREATE SQL VIEW "TEST" ;
> AS SELECT genericcode.* FROM genericcode genericcode ;
>WHERE genericcode.genericcodecategory == 'Labor Class'
>
>use test in 0
>cursorsetprop('buffering', 5, 'test')
>dbsetprop('test', 'View', 'SendUpdates', .t.)
>select test
>brow
>* manually change some data
>? tableupdate(1,.t.,'test')
>set
>
>return
>
>function works
>
>close databases all
>open database payroll
>use test in 0
>cursorsetprop('buffering', 5, 'test')
>dbsetprop('test', 'View', 'SendUpdates', .t.)
>select test
>brow
>* manually change the data
>? tableupdate(1,.t.,'test')
>
>return
------------------------------------------------
John Koziol, ex-MVP, ex-MS, ex-FoxTeam. Just call me "X"
"When the going gets weird, the weird turn pro" - Hunter Thompson (Gonzo) RIP 2/19/05
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform