I need to be able to report downtime on our machines using a 16 hour clock; Ie: from 6am to 10pm. I have the data for the open and close dates of the calls. For instance if a call was opened on 8/15/03 at 4 am and closed on 8/20/03 at 9 pm the only downtime counted against it would be for the hours each day between 6am and 10 pm. this is easy to calculate for a single day but I'm having trouble writing a query to cover multiple days. Any ideas?