how to set master detail on ADOQuery
1. How do I set up the master detail relationship between ADODataset or
ADOQuery?
I do not see the mastersource property, only the masterfield.
2. How do I start printing the detail report on the same line right after
the master record.
for example, a Customer and Order report
customer st order date order no
-----------------------------------------------------------
ABC NY 1/4/2001 200011
1/6/2001 200022
BAC CA 1/3/2001 200002
5/3/2001 200282
ADOQuery?
I do not see the mastersource property, only the masterfield.
2. How do I start printing the detail report on the same line right after
the master record.
for example, a Customer and Order report
customer st order date order no
-----------------------------------------------------------
ABC NY 1/4/2001 200011
1/6/2001 200022
BAC CA 1/3/2001 200002
5/3/2001 200282
This discussion has been closed.
Comments
property DataSource: TDataSource;
Description
Set DataSource to automatically fill parameters in a query with fields
values from another dataset. Parameters that have the same name as fields in
the other dataset are filled with the field values. Parameters with names
that are not the same as fields in the other dataset do not automatically
get values, and must be programmatically set. For example, if the SQL
property of the TADOQuery contains the SQL statement below and the dataset
referenced through DataSource has a CustNo field, the value from the current
record in that other dataset is used in the CustNo parameter:
SELECT *
FROM Orders O
WHERE (O.CustNo = :CustNo)
...
Cheers,
Jim Bennett
Digital Metaphors
http://www.digital-metaphors.com
info@digital-metaphors.com