Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Parent / Child One to mainy on a form
Message
From
06/04/2003 10:48:14
 
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00774523
Message ID:
00774527
Views:
14
If you SET a RELATION from a parent table into a child table, and browse the child table, you only see records which match the parent, right? You can do this in the command window with 2 USEs, a SET RELATION, and 2 BROWSEs. But, this only works when the child table is not SELECTed. If you SELECT Child, then BROWSE, you see the whole child table. So, that's the first thing to check.

It has also been my experience that clicking in the grid can sometimes seem to have the same effect as clicking a BROWSE window interactively, that is, it SELECTs the RecordSource of the grid. In the command window example, if you click the unselected BROWSE window you will see a SELECT statement appear in the command window. This could be the problem if the grid is the first control to receive focus when the page is entered.

The properties I set on the grid to get one-to-many are:
RecordSource: My Child Table
LinkMaster: My Parent Table
ChildOrder: Index Tag Of My Child Table
RelationalExpr: Field Or Expression following the "TO" clause of an ordinary SET RELATION, i.e., Parent.Field taht matches child index tag.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform