[AccessD] Report/Sub report question.

Jim Hewson JHewson at karta.com
Mon Mar 24 09:34:41 CST 2003


Bobby,
One question comes to mind.  Can a Prime Contractor also be a sub
contractor?
If so, then I would suggest creating a table to record the 1-M
relationships.
Two fields labeled Prime and Sub is all that is needed.
So the data would look like:
Prime	Sub
A	B
A	C
A	D
B	A
B	E

Etc.

The reason to do it this way is that a Prime Contractor on one contract can
be a Sub contractor for another.  Unless a Prime will always be a prime and
sub will always be a sub.

If the tier code is one field in the primary table, I'm not sure how you
would separate the data to what you need.  e.g. if a company is prime and
ONLY a prime, how do you determine what companies are the subs?

Maybe I don't understand how it works.

Yes, the field needs to be available on the report.

I'm confused, but that's my normal state....

Jim
 

-----Original Message-----
From: Bobby Heid [mailto:bheid at appdevgrp.com]
Sent: Monday, March 24, 2003 8:31 AM
To: accessd at databaseadvisors.com
Subject: RE: [AccessD] Report/Sub report question.


Hi Jim,

The two reports pull different data based upon a tier code.  The primary
report pulls data for tier 0, and the sub report pulls data for tier<>0.
The reason I need to do it this way is that the report is required to show a
different subtotal for the tier 0 records and one total of all of the
records for the tiers under that one tier.  Note that there can be many tier
0 records.  The tier 0 records are primary contractors and the tier<>0
records are sub contractors under that contractor.

When you say that the field needs to be visible, are you saying visible on
the report or available to display on the report (IE. in the query)?

Hope I haven't confused everyone even more.  LOL.

Thanks,
Bobby

-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com]On Behalf Of Jim Hewson
Sent: Monday, March 24, 2003 9:18 AM
To: 'accessd at databaseadvisors.com'
Subject: RE: [AccessD] Report/Sub report question.


Bobby,
It seems to me, there is a normalization problem.
Sub reports/forms are used to display a one to many relationship.  If "the
main report and sub report ... pull from the same table" that indicates a
one to one relationship and there is no need for a sub report.

To insure a sub report works correctly, the common field between the main
report and sub report needs to be visible to both.

HTH
Jim

_______________________________________________
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com


More information about the AccessD mailing list