Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Updateable view of updateable view
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
The Mere Mortals Framework
Versions des environnements
Visual FoxPro:
VFP 8 SP1
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
Visual FoxPro
Application:
Desktop
Divers
Thread ID:
01433144
Message ID:
01433207
Vues:
49
>>I've used views of views before without issue, but apparently they were all non-updateable and I didn't realize it. I'm trying to do an updateable view of an updateable view, and the View Designer isn't having it. The view was using v_otherview as an apparent free table, but the DBSETPROP statements use Database!lv_otherview. Manual changes to "v_otherview" were undone when saved.
>>
>>Can this be done, or do I need to change lv_otherview to do what I created lv_viewofview for?
>
>I've done this before and managed to get it to work just fine (although I always hear people tell me I'm nuts for doing it) - but I've never had a problem using this logic....so....
>What version of VFP are you using? Are both views local views? Or is this first one a remote view? And are both views in the same DBC?

Version: Look up 12 lines ;) VFP 8 SP 1. Both are local and in the same DBC. The Mere Mortals framework business objects take the lv_ prefix and strip off the first letter to use v_viewname aliases.

SELECT v_viewname.id, v_viewname.date, v_viewname.fullname, v_viewname.amount FROM v_viewname V_viewname ;
WHERE ?vp_id = 0 or v_viewname.id = ?vp_id ORDER BY v_viewname.fullname, v_viewname.date

DBSetProp(ThisView+".id","Field","DataType","I")
DBSetProp(ThisView+".id","Field","UpdateName","dbc!lv_viewname.id")
DBSetProp(ThisView+".id","Field","KeyField",.F.)
DBSetProp(ThisView+".id","Field","Updatable",.T.)

As shown, I never use DBC.lv_viewname, but View Designer insists that's the updatable table. What do your DBSetProps look like?
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform