Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Inserting Records Through a View
Message
De
29/12/1999 09:08:17
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
 
À
28/12/1999 19:37:20
Information générale
Forum:
Visual FoxPro
Catégorie:
Visual FoxExpress
Divers
Thread ID:
00309437
Message ID:
00309790
Vues:
28
>>Hi Guys
>>
>>I have a Presentation Object on a Form Presentation Object that is based on a View
>>
>>When I try to insert a record into this view i get the following error message:
>>
>>"Cannot insert an empty row from a view into its base tables(s)"
>>
>>What can I do to solve this
>>
>>Thank You
>>
>>Gary
>
>This is usually because the view definition has updatable fields from more than one table. When you do a TABLEUPDATE(), VFP attempts to insert a record into both underlying tables. If you check your view, and find that only fields from a single table are set as updatable, remove all but the true updatable table name from the view's Tables property using DBSETPROP(). FWIW, my eView utility makes tweaking views like this much easier than wrestling with DBSETPROP commands. You can get here from the files section.


Erik,
I second on your reply.
I dropped really to request an enhancement to eview if you don't mind (great I use it instead of manually coding all those update code-thanks:).
Could you add a column to updatable field list to define actual sources so I could bypass manually entering "myDBC!myTable.myField" in code :) Actually none of the views I create are things that VFP designer could handle and so I rewind to your eview much, I would love entering sources there. If this is asking for too much just consider I didn't request :) Thanks.
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform