Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to programmatically add a table to a view?
Message
 
À
12/07/1998 01:11:46
Larry Long
ProgRes (Programming Resources)
Georgie, États-Unis
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00116567
Message ID:
00116569
Vues:
13
Hi Larry,

You can create a parameterized view such as
SELECT * FROM YourTable WHERE YourTable.cParentId = ?vp_cParentId
This way, you can define the value of variable vp_cParentId and issue a REQUERY().

>I am displaying/editing parent and child records from within a formset. I am using a parent view and a child view. I can create the views thru the view designer for testing, but I need to be able to programmatically create and save the views in a database, that allows me to display the child records when navigating thru my parent records, without using the view designer.
>
>No problem creating the parent view.
>
>How do I add the parent view to the child view without setting up a relationship, so I can run the query...
>
>SELE * FROM childtable WHERE childtable.parentkey=parenttable.keyfield
>
>I have tried using DBSETPROP with the TABLES property, and although the changes are save, I have to open the parent table before I can open the child view.
>
>In the view designer I would simply add the parent view to the data environment, then create the view.
>
>PHIS!
>(Please Help...I'm Stumpped!)
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform