Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to handle Child records from Child table
Message
General information
Forum:
Visual FoxPro
Category:
Reports & Report designer
Miscellaneous
Thread ID:
00835794
Message ID:
00835834
Views:
17
You can do this a couple of ways. One way would be to set a relation between the parent and child table, then set the child table to the current table and drive the report from the child table. Define a Data Group based on the common field and put all your general parent info in the data group header. Put all the child data in the detail band.

If you have any situations where you have a parent record w/o any child records, then the above scenario needs to be done a little differently by using SET SKIP.

Another way is to use a SQL SELECT statement, joining the parent and child tables so you have one cursor with all the information you need. Then drive the report from this cursor instead of the original tables.

Cathy



>I have a report which has parent -> child table data. The parent table has general field data, and if there is a join to child table based on PK-FK relationship then the child tables' data (1 or more records) will be displayed nested beneath the general field data on report.
>
>I am using VFP8. How do I do this. The Help Doc is not crystal clear in explaining this situation.
>
>Fred Z.
Cathy Pountney, Microsoft Visual FoxPro MVP
Memorial Business Systems, Inc. (www.mbs-intl.com)

My Website: (www.frontier2000.com)
My Blog: (www.cathypountney.blogspot.com)
My Book: The Visual FoxPro Report Writer - Pushing it to the Limit and Beyond
Free MSDN Article: What's New in the VFP 9.0 Report Writer
Free MSDN Article: The VFP 9.0 Report Writer In Action
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform