handle date range