sql时间重合查询,时间交叉查询
[sql]
select * from ERP_Support_date esd
where esd.support_start_date between to_date('2013-03-01 18:30:00','yyyy-MM-dd hh24:mi:ss')
and to_date('2013-03-01 19:00:00','yyyy-MM-dd hh24:mi:ss')
or esd.support_end_date between to_date('2013-03-01 18:30:00','yyyy-MM-dd hh24:mi:ss')
and to_date('2013-03-01 19:00:00','yyyy-MM-dd hh24:mi:ss')
查询'2013-03-01 18:30:00' -'2013-03-01 19:00:00'
包含这半小时时间段的所以时间