oracle数据库中 当where日期为变量,请问语句怎么写

2025年03月23日 09:05
有1个网友回答
网友(1):

select * from t where time>=to_char(to_date('2015-4-20','yyyy-mm-dd'),'yyyy/mm/dd') and time<=to_char(to_date('2015-4-20','yyyy-mm-dd')+4,'yyyy/mm/dd');
5天内,即当天再加4天。