Report display difficulty

  • Thread starter Thread starter Gail
  • Start date Start date
G

Gail

Hi,

I have a parent tblWorkCover with a child tblMedCerts and
a second child tblAdditionalInfo. tblMedCerts and
tblAdditionalInfo have no direct relationship to each
other.

ie SELECT * FROM ((tblWorkCover LEFT JOIN tblMedCerts ON
tblWorkCover.Id = tblMedCerts.WCId)LEFT JOIN
tblAdditionalInfo ON tblWorkCoverId =
tblAdditionalInfo.WCId)GROUP BY tblWorkCover.Id

I need to print a report which will list each tblWorkCover
case with a list of the associated MedCerts and a list of
the AdditionalInfo.
eg
WorkCover Name
Cert 1
Cert 2
Info 1
Info 2
Info 3
Info 4
At present I am getting a duplication of the all the Info
displayed again for each Cert. Problem is the Info does
not relate to an individual Cert. I can print 2 reports 1
with WorkCover and Cert and the second with WorkCover and
AdditionalInfo but all on one page is desirable.

All help appreciated.
Gail
 
Gail said:
I have a parent tblWorkCover with a child tblMedCerts and
a second child tblAdditionalInfo. tblMedCerts and
tblAdditionalInfo have no direct relationship to each
other.

ie SELECT * FROM ((tblWorkCover LEFT JOIN tblMedCerts ON
tblWorkCover.Id = tblMedCerts.WCId)LEFT JOIN
tblAdditionalInfo ON tblWorkCoverId =
tblAdditionalInfo.WCId)GROUP BY tblWorkCover.Id

I need to print a report which will list each tblWorkCover
case with a list of the associated MedCerts and a list of
the AdditionalInfo.
eg
WorkCover Name
Cert 1
Cert 2
Info 1
Info 2
Info 3
Info 4
At present I am getting a duplication of the all the Info
displayed again for each Cert. Problem is the Info does
not relate to an individual Cert. I can print 2 reports 1
with WorkCover and Cert and the second with WorkCover and
AdditionalInfo but all on one page is desirable.


This situation is best handled with subreports. Instead of
Joining the tables in the query, create a separate report
for each table. Then include the two child reports as
subreports in the detail section of the work cover report.
Use the subreport control's Link Master/Child properties to
link the main report record's ID field to the WCId field in
the subreports.
 
Back
Top