Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Buffering and Tableupdate()
Message
De
13/04/2006 12:48:59
Mike Yearwood
Toronto, Ontario, Canada
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Divers
Thread ID:
01113462
Message ID:
01113503
Vues:
20
>Start with CursorAdapter and you will forget the View :o)

Agreed!

>
>>>>If the controls on a form display and operate on data contained in a temporary cursor, how do you save the revised data back into the original table? I'm experimenting with the following code sequence to try and figure this out but I can't seem to get it right.
>>>>
>>>>
>>>>select * from test_financing into cursor crstemp readwrite
>>>>set multilocks on
>>>>=cursorsetprop("buffering",5,"test_financing")
>>>>select crstemp
>>>>go top
>>>>replace amount with 2000
>>>>=tableupdate()
>>>>
>>>>
>>>>Any help will be appreciated.
>>>
>>>Don
>>>
>>>1. You select the newly created cursor in which to do the change and buffer it, so TableUpdate()ing won't affect the test_financing table
>>>
>>>2. Strikes me that the whole exercise is futile. With buffering, your changes are effectively made to the buffer and only reflected in the table after update. So why copy it all to a cursor too?
>>>
>>>3. Even if you used a view, what's the point of having a view of the whoile unadulterated table, with no related data from others?
>>>
>>>HTH
>>>
>>>Terry
>>
>>Terry -
>>From the limited picture I provided you would be right. You may also be right even after the bigger picture is known. I have been using the Fox for over 10 years now and have never found a need or use for views. however lately several of my "helpers" here on UT have suggested that I need to learn how they work so I thought I would give it a try.
>>
>>I this particular case, the view would become a filtered list of records that would be joined to a parent table and would be shown in a grid. I have 9 or 10 of these little grids on the form each displaying a subset of the available records. (each grid contains the records for 1 year). Others here at UT have suggested a view would be better than a filtered table but I'm not so sure at this point until I learn more about views. CursorAdapter will be next on my list to explore.
>>
>>Thanks
>>-Don
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform