3,499
社区成员
发帖
与我相关
我的任务
分享begin
if (sysdate between (trunc(sysdate)+7/24) and (trunc(sysdate)+19/24)) then
dbms_output.put_line('between 7.am and 7.pm');
end if;
end;
begin
if (to_number(to_char(sysdate, 'hh24')) between 7 and 19) then
dbms_output.put_line('between 7.am and 7.pm');
end if;
end;if((to_char(sysdate,'hh')>=7 and to_char(sysdate,'hh')<=19) then
end if;
if(to_date(to_char(sysdate,'hh24:mi:ss'),'hh24:mi:ss')>to_date('07:00:00','hh24:mi:ss') and to_date(to_char(sysdate,'hh24:mi:ss'),'hh24:mi:ss')<to_date('19:00:00','hh24:mi:ss')) then
end if;