Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Is there a way to Append and Delete from a View?
Message
De
19/06/1997 14:31:14
 
 
À
19/06/1997 12:29:18
Information générale
Forum:
Visual FoxPro
Catégorie:
Client/serveur
Divers
Thread ID:
00036808
Message ID:
00037015
Vues:
32
>Steve,
>
>I have yet to have the pleasure of updating a view, but do remember reading something which struck me as rather odd and cumbersome when reading the manuals on the subject. Specifically, it said that views of views must have all levels of the views updated in order for the base tables to be updated. I have no idea how this is accomplished.
>
>But if yours is a view of a view, that could be it.
>
>good luck
>Jim N
>
>>>Hello!
>>>
>>>Recently I have had play with this and have curious results. When you check
>>>Send SQL updates in View designer, then all changes in view goes in parent
>>>table immediately and you cannot make the rollback ;( (tablerevert()
>>>doesn't work) For deleteting records you can use Delete command. May be
>>>I'm misunderstand your question?
>>>
>>>Have a happy day
>>>Vladimir Shevchenko
>>>
>>>> The title says it all. Has anyone found a way to create new records or
>>>> delete records from a view? Is it my correct understanding that one can
>>>> only "update" existing data in a view?
>>
>>Hi Vladimir,
>>
>>I do not use the View Designer as some of our views will be far to complex for it. All is done through code. I gone through the whole DBSETPROP bit, including tables, keys, names, updatable, and sendupdates. I have a transaction class that issues the tableupdate() function and it returns .T. so all apparently went well. The view is updated on the form, but the underlying table does not get updated.
>>
>>Steve Despres

Steve...
to save the record from a view to a table, I use...
=cursorsetprop("keyfieldlist",'your ley field's name')
=cursorsetprop("sendupdates",.t.)
=cursorsetprop('UpdatableFieldList','field1,field2,etc')
works all the time...hopes this helps...rob
Robert Keith
Independent Developer
San Antonio, Texas
E-mail address:
rebelrob1@yahoo.com
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform