I have 4 files that have a 1-many relationship.
The 1-side of the relationship is a file called Events with the primary key being Event ID and Event Date.
There are 3 files in the many relationship.
Event Contributions: Event ID, Event Date, Contribution ID, Contribution Amount.
Event Receipts: Event ID, Event Date, Receipt ID, Receipt Amount.
Event Expense: Event ID, Event Date, Expense ID, Expense Amount.
I’m trying to create a single query that will summarize by Event ID and Date, Total Contributions, Total Receipts, Totals Expenses and calculate Profit/Loss.
The problem is I’m getting the wrong totals when summarizing and I think it has to do with that fact that each of the many-side files may not contain a record for that Event ID and Event Date.
Also, all the Event ID/Event Date Combinations are not being displayed unless there is a record in each of the many-side files
If I change the Join Properties to #2 include all records from the Events file and only those records from the many-side file where the joined fields equal, I get the following message when trying to execute the query:
The SQL statement could not be executed because it contains ambiguous outer joins. To force one of the joins to be performed first, create a separate query that performs the first join and then include that query in you SQL statement.
I have no idea what direction the above statement is pointing me.
Any help would be greatly appreciated.
Thanks In Advance,
Dan
The 1-side of the relationship is a file called Events with the primary key being Event ID and Event Date.
There are 3 files in the many relationship.
Event Contributions: Event ID, Event Date, Contribution ID, Contribution Amount.
Event Receipts: Event ID, Event Date, Receipt ID, Receipt Amount.
Event Expense: Event ID, Event Date, Expense ID, Expense Amount.
I’m trying to create a single query that will summarize by Event ID and Date, Total Contributions, Total Receipts, Totals Expenses and calculate Profit/Loss.
The problem is I’m getting the wrong totals when summarizing and I think it has to do with that fact that each of the many-side files may not contain a record for that Event ID and Event Date.
Also, all the Event ID/Event Date Combinations are not being displayed unless there is a record in each of the many-side files
If I change the Join Properties to #2 include all records from the Events file and only those records from the many-side file where the joined fields equal, I get the following message when trying to execute the query:
The SQL statement could not be executed because it contains ambiguous outer joins. To force one of the joins to be performed first, create a separate query that performs the first join and then include that query in you SQL statement.
I have no idea what direction the above statement is pointing me.
Any help would be greatly appreciated.
Thanks In Advance,
Dan