Guys,

I am a Novice, need you help on the below table. Data Represented from Row A to E and Column 1 to 14.



TABLE.

(A) (B) (C) (D) (E)
(1) Date Start Time End Time Duration Refrence Number
(2) 21-Dec-11 16:32:05 16:32:07 00:00:02 123456
(3) 21-Dec-11 16:32:05 16:32:07 00:00:02 123456
(4) 21-Dec-11 16:32:08 16:32:09 00:00:01 123456
(5) 22-Dec-11 16:32:05 16:32:07 00:00:02 123456
(6) 22-Dec-11 16:32:08 16:32:09 00:00:01 123456
(7) 22-Dec-11 16:32:05 16:32:07 00:00:02 123456
(8) 22-Dec-11 17:34:37 17:34:38 00:00:01 123456
(9) 22-Dec-11 17:34:39 17:34:40 00:00:01 123456
(10) 22-Dec-11 17:34:41 17:34:41 00:00:00 123456
(11) 23-Dec-11 18:21:43 18:21:44 00:00:01 123456
(12) 23-Dec-11 18:21:45 18:21:45 00:00:00 123456
(13) 23-Dec-11 19:02:02 19:02:03 00:00:01 123456
(14) 23-Dec-11 19:02:03 19:02:04 00:00:01 123456



What I am looking for is a formula that sorts the data in the below intervals
So when I type the date in cell "B1" , I want the formula such that "C3" scands the table above for only the selected date and returns me the count of refrence numbers in the corresponding interval.
EG. "C3" for 21st Dec shoudl give "0" and "C4" should give "4"



(A) (B) (C)
(1) ENTER DATE 21-Dec-11

(2) INTERVAL INTERVAL Count
(3) 16:00:01 16:30:00 ___
(4) 16:30:01 17:00:00 ___
(5) 17:00:01 17:30:00 ___
(6) 17:30:01 18:00:00 ___
(7) 18:00:01 18:30:00 ___
(8) 18:30:01 19:00:00 ___