Skip to content
Advertisement

How to retrieve rows between hours

I want to get all rows from my table, the table have one column with the following date type ’14/07/2017 05:01:35 p.m.’ between specific hours. Like between ’00:01:00 am’ and ’01:00:00 am’.

I’m running Oracle Database 11g Release 2

I want to select hours instead of dates.

Advertisement

Answer

If you mean (from your last comment) that you want to get all records that are between the dates of Jan 1st 2019 and Apr 4th 2019, but only if the time portion of the recod is between 12:01AM and 1:00AM, then you could try this:

User contributions licensed under: CC BY-SA
2 People found this is helpful
Advertisement