I'm attempting to put together a query and report to do some calculations. It's pulling from 3 tables and I need to apply some criteria depending on what a certain value is.
I have 3 tables: tblObligations, tblPayments, and tblReclaimed.
tblObligations has a ProgramYear field (ex. 2005) and Obligation ($ Currency). The other 2 tables have a Date field and Amount.
I'm attempting to get the Sum of Obligations by Year then subtract out the amounts from each of the Payments and Reclaimed table. The downside is that the year is done from July to June; so Program Year 2007 runs from July 1st 2007 to June 30th 2008.
Is there any good way to do this?
I would like to do it so the report or whatever shows:
If you need any more clarification let me know. I'll be happy to get more indepth.
Thanks,
I have 3 tables: tblObligations, tblPayments, and tblReclaimed.
tblObligations has a ProgramYear field (ex. 2005) and Obligation ($ Currency). The other 2 tables have a Date field and Amount.
I'm attempting to get the Sum of Obligations by Year then subtract out the amounts from each of the Payments and Reclaimed table. The downside is that the year is done from July to June; so Program Year 2007 runs from July 1st 2007 to June 30th 2008.
Is there any good way to do this?
I would like to do it so the report or whatever shows:
Code:
ProgramYear ObligationSum PaymentsSum ReclaimSum Remng
==========================================================
2005 $30,000 $20,000 $1,000 $9,000
2006 $8,000 $2,000 $0.00 $6,000
etc...
If you need any more clarification let me know. I'll be happy to get more indepth.
Thanks,