Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
Not sure if this is possible...
I have a table with a date range for each record:
table 1 | ||
ID | Date1 | Date2 |
record1 | 11/01/2011 | 15/01/2011 |
record2 | 15/06/2011 | 31/07/2011 |
I have a second table with event dates:
table2 |
Event_Date |
12/01/2011 |
14/01/2011 |
17/06/2011 |
30/06/2011 |
05/07/2011 |
What I want to do is create a new table, from table1 but with a new column showing how many event dates from table2 exist between Date1 & Date2:
table3 | |||
ID | Date1 | Date2 | Events |
record1 | 11/01/2011 | 15/01/2011 | 2 |
record2 | 15/06/2011 | 31/07/2011 | 3 |
Any advice would be much appreciated.
Regards,
Phil
hei
actualy there is a solution it called interval match
have a look at the example file script and tables erd
hope it helps you
hei
actualy there is a solution it called interval match
have a look at the example file script and tables erd
hope it helps you
Thank you so much for this... what a great solution!
Kind Regards,
Phil