Forum Stats

  • 3,727,089 Users
  • 2,245,319 Discussions
  • 7,852,583 Comments

Discussions

EFCore with query comparing Time

mariohik
mariohik Member Posts: 11 Green Ribbon

Using EFCore, how can I compare just the time of a timestamp?

SELECT * FROM MY_TABLE WHERE TO_CHAR(TIMESTAMP_COLUMN, 'hh24:mi') >= '06:00' AND TO_CHAR(TIMESTAMP_COLUMN, 'hh24:mi') <= '06:05'

I have the Timestamp translated do DateTime, but I can't call .TimeOfDay to do this comparison.

Best Answer

Answers

Sign In or Register to comment.