DB/ORACLE
[oracle] sysdate
펭귄대장
2021. 2. 8. 17:03
* 현재시각 2021/02/08 17시일때
select * from where tdate > sysdate-1;
: 2/7 17시 이후 데이터
select * from where trunc(tdate) > trunc(sysdate)-1;
: 2/8 0시 이후 데이터
select * from where tdate > trunc(sysdate)-1;
: 2/7 0시 이후 데이터
반응형