theKruser
Registered User.
- Local time
- Today, 06:44
- Joined
- Aug 6, 2008
- Messages
- 122
I have a table that has multiple related tables. I am trying to display (in a from) the total record count of all related tables per record in the main table, but I do not know how to build the query...or if I should be using VBA. For example suppose:
tblCompany
tblPayable
tblRecievable
Desired Result (simulated table with "|" as delimiter):
CompanyName | Payable | Recievable
CompanyA | Total # Payable | Total # Receivable
-Section1 | Payable | Receivable
-Section2 | Payable | Receivable
CompanyB | Total # Payable | Total # Receivable
-Section1 | Payable | Receivable
-Section2 | Payable | Receivable
Any help would be greatly appreciated
tblCompany
-CompanyID (PK)
-ParentCompanyID (used for sections within the company, using CompanyID as FK)
-CompanySectionName
-ParentCompanyID (used for sections within the company, using CompanyID as FK)
-CompanySectionName
tblPayable
-PayableID
-Data1 (etc, etc)
-Data1 (etc, etc)
tblRecievable
-RecievableID
-Data1 (etc, etc)
-Data1 (etc, etc)
Desired Result (simulated table with "|" as delimiter):
CompanyName | Payable | Recievable
CompanyA | Total # Payable | Total # Receivable
-Section1 | Payable | Receivable
-Section2 | Payable | Receivable
CompanyB | Total # Payable | Total # Receivable
-Section1 | Payable | Receivable
-Section2 | Payable | Receivable
Any help would be greatly appreciated