1. 程式人生 > >oracle中查詢某個時間段內的資料

oracle中查詢某個時間段內的資料

例子:

1)select * from tableName t where start_times > to_date('2015/6/26 10:00:00','yyyy/mm/dd hh24:mi:ss');

2)select * from tableName t where start_times < to_date('2015/6/26 10:00:00','yyyy/mm/dd hh24:mi:ss');

3)select * from tableName t where start_times between to_date('2015/6/26 10:00:00','yyyy/mm/dd hh24:mi:ss') and to_date('2015/6/26 11:00:00','yyyy/mm/dd hh24:mi:ss');