I have an Oracle DATE column with, for example, these values:
RUN_DATE
-------------------
2012-06-09 13:15:00
2012-06-10 14:28:00
2012-06-11 12:20:00
2012-06-12 13:14:00
2012-06-13 11:50:00
I want to select those values that occurred within a hour of 13:00.
For the data above that would be the 1st, 3rd, and 4th rows.
Thank you
will work. Of course, you’ll probably need a function-based index on
to_char(run_date, 'HH24:MI' )to make it run efficiently.