My database is based on Work Order Numbers. If an employee enters labor, they must include the WO Number for it. Equipment, subcontractors, per diem and materials all must also have a WO number.
I have the following tables:
Work Orders
Labor (includes per diem and time entries)
Equipment
Subcontractors
Materials
I have created a summary report using the Materials table which lists the WO number, total labor, total equipment, total subc's, and total materials, if any, within a user-specified date range.
The totals of labor, per diem, equipment, subc's and materials use the DSum function.
The problem is that since I created the report based off of the Work Orders table, it lists all of the work orders, not just the ones which have transactions from any or all of the other tables. Is there some SQL or a query I can create to only show the work orders which have transactions from the other tables during the specified date range?