Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How to compare two date column time data in where clause

Fahad AkhtarJun 11 2017 — edited Jun 12 2017

I have a sales data store in a table as below

DATE                                     AMOUNT

10-JUN-2017 6:00:00            1000

10-JUN-2017 14:00:00          500

11-JUN-2017 01:00:00          1000

11-JUN-2017 03:00:00          200

11-JUN-2017 18:00:00          100

11-JUN-2017 23:00:00          600

12-JUN-2017 02:00:00          50

12-JUN-2017 03:00:00          70

Now I want to extract the sales amount during the 02:00:00 of 12th June, means all sales < '02:00:00' (2:00:00 is not fixed it based on sysdate time). Means I need to match the time in date column.

Regards

This post has been answered by Frank Kulash on Jun 11 2017
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jul 10 2017
Added on Jun 11 2017
15 comments
12,636 views