January 11th, 2004, 07:26 PM
how do I filter the time field in oracle
I have a table
What I actually required is the mydate (18-Jan-2004), starttime( 05:00 pm), endtime (06:00 pm).
I am storing the data as follow:
mydate 18-Jan-2004 12:00:00 AM
starttime 18-Jan-2004 05:00:00 PM
endtime 18-Jan-2004 06:00:00 PM
Is there a better way to store these information?
Say I current machine time (not the server time) is 04:00 PM and I would like to use this information to find id which starttime is later than 04:00 PM. Should I use to_date or is there a better way to construct the SQL statement?
January 12th, 2004, 09:56 AM
Have you tried using the `interval 'n' ` function?
where current_date > sysdate + interval '4' hour;