R
Renetta
Please help - I need to run a query between two tables
The two tables are linked by the
[Account#]. The date formate for both tables [GranceDate] and [PaymentDate]
are in Date/Time formate.
What I need is:
In the Grace_tbl return all accounts [Account#] along with their grace
ending date [GraceDate] and from the Payments_tbl return only those matching
accounts [Account#]with a [Payment] and [PaymentDate] range of 0-30, 31-60
and 61-90
Sample qry below - I need to limite it to only those payments that fall into
the aging listed above.
Grace_tbl [Client] Grace_tbl [Fund] Grace_tbl [Account #] Grace_tbl [Grace
Date] Payment_tbl [Account #] Payment_tbl [Payment Date] Payment_tbl [Payment]
581 97 111111111 12/1/2004 111111111 9/29/2005 1,489.00
581 97 111111111 12/1/2004 111111111 2/1/2005 50.00
581 97 111111111 12/1/2004 111111111 2/18/2005 50.00
581 97 111111111 9/1/2004 111111111 9/29/2005 1,489.00
581 97 111111111 9/1/2004 111111111 2/1/2005 50.00
581 97 111111111 9/1/2004 111111111 2/18/2005 50.00
581 97 2222222222 12/1/2005 2222222222 9/4/2007 43.49
581 97 2222222222 12/1/2005 2222222222 9/4/2007 43.49
581 97 2222222222 12/1/2005 2222222222 8/28/2006 43.49
581 97 2222222222 12/1/2005 2222222222 8/7/2007 86.98
581 97 2222222222 12/1/2005 2222222222 10/9/2006 43.49
581 97 2222222222 12/1/2005 2222222222 5/1/2006 43.49
581 97 2222222222 12/1/2005 2222222222 12/31/2007 43.49
581 97 2222222222 12/1/2005 2222222222 3/22/2006 43.49
581 97 2222222222 12/1/2005 2222222222 4/4/2007 86.98
581 97 2222222222 12/1/2005 2222222222 11/30/2007 43.49
581 97 2222222222 12/1/2005 2222222222 11/5/2007 43.49
581 97 2222222222 12/1/2005 2222222222 6/5/2006 43.49
581 97 2222222222 12/1/2005 2222222222 2/6/2006 43.49
581 97 2222222222 12/1/2005 2222222222 1/2/2006 43.49
581 97 2222222222 12/1/2005 2222222222 7/23/2007 86.98
581 97 2222222222 12/1/2005 2222222222 11/6/2006 86.98
581 97 2222222222 12/1/2005 2222222222 12/4/2006 86.98
581 97 2222222222 12/1/2005 2222222222 7/13/2006 43.49
581 97 2222222222 12/1/2005 2222222222 7/28/2006 86.96
581 97 2222222222 12/1/2005 2222222222 1/25/2007 43.49
581 97 2222222222 12/1/2005 2222222222 2/28/2006 86.98
Thanks.
The two tables are linked by the
[Account#]. The date formate for both tables [GranceDate] and [PaymentDate]
are in Date/Time formate.
What I need is:
In the Grace_tbl return all accounts [Account#] along with their grace
ending date [GraceDate] and from the Payments_tbl return only those matching
accounts [Account#]with a [Payment] and [PaymentDate] range of 0-30, 31-60
and 61-90
Sample qry below - I need to limite it to only those payments that fall into
the aging listed above.
Grace_tbl [Client] Grace_tbl [Fund] Grace_tbl [Account #] Grace_tbl [Grace
Date] Payment_tbl [Account #] Payment_tbl [Payment Date] Payment_tbl [Payment]
581 97 111111111 12/1/2004 111111111 9/29/2005 1,489.00
581 97 111111111 12/1/2004 111111111 2/1/2005 50.00
581 97 111111111 12/1/2004 111111111 2/18/2005 50.00
581 97 111111111 9/1/2004 111111111 9/29/2005 1,489.00
581 97 111111111 9/1/2004 111111111 2/1/2005 50.00
581 97 111111111 9/1/2004 111111111 2/18/2005 50.00
581 97 2222222222 12/1/2005 2222222222 9/4/2007 43.49
581 97 2222222222 12/1/2005 2222222222 9/4/2007 43.49
581 97 2222222222 12/1/2005 2222222222 8/28/2006 43.49
581 97 2222222222 12/1/2005 2222222222 8/7/2007 86.98
581 97 2222222222 12/1/2005 2222222222 10/9/2006 43.49
581 97 2222222222 12/1/2005 2222222222 5/1/2006 43.49
581 97 2222222222 12/1/2005 2222222222 12/31/2007 43.49
581 97 2222222222 12/1/2005 2222222222 3/22/2006 43.49
581 97 2222222222 12/1/2005 2222222222 4/4/2007 86.98
581 97 2222222222 12/1/2005 2222222222 11/30/2007 43.49
581 97 2222222222 12/1/2005 2222222222 11/5/2007 43.49
581 97 2222222222 12/1/2005 2222222222 6/5/2006 43.49
581 97 2222222222 12/1/2005 2222222222 2/6/2006 43.49
581 97 2222222222 12/1/2005 2222222222 1/2/2006 43.49
581 97 2222222222 12/1/2005 2222222222 7/23/2007 86.98
581 97 2222222222 12/1/2005 2222222222 11/6/2006 86.98
581 97 2222222222 12/1/2005 2222222222 12/4/2006 86.98
581 97 2222222222 12/1/2005 2222222222 7/13/2006 43.49
581 97 2222222222 12/1/2005 2222222222 7/28/2006 86.96
581 97 2222222222 12/1/2005 2222222222 1/25/2007 43.49
581 97 2222222222 12/1/2005 2222222222 2/28/2006 86.98
Thanks.