Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
2 Tables, One Form
Message
 
 
To
27/05/1999 15:08:17
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00223537
Message ID:
00223703
Views:
22
>I don't know how your form is set up. The way I normally build a parent-child form is by placing the parent control on the form and adding a read-only grid for the child. I would add 3 command button: Add, Modify and Delete. The first two buttons would display a modal form to add all the information about the child.
>
>In the Save method of the child form, I would issue a INSERT-SQL to the child table if the Add button was selected in the parent table.
>
>In the Save method of the parent form, I would put a TableUpdate() for the parent table and a second one for the child table. TableRevert() for the Cancel method.
>
>Naturally, this require a record/table buffering for the parent table and table buffering for the child table.
>
>HTH
>
>>Thanks for your reply!:) I really needed someone to verify my fears...ok, I see what you are saying, can you give an example, or suggestion on how to do this?


Well wait just a sec...isn't one of the things about relational databases is that you can have several tables, all linked together in a DBC, and can be edited, AND added to, without adding to each individually? This seems wierd to me...I mean, if you've got a table that has invoice #s, customer #s, etc. and then you have seperate tables that have the details about that invoice #, customer, etc. and you're entering invoices and customer info on one form, that you have to do an insert for EACH table? Please straighten my logic/reasoning...
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform