>>>An exact match and >= or (worse) BETWEEN are not the same thing.
>
>The OP asks about using LIKE which IMHO will involve an explicit or implicit cast to string that's unlikely to benefit from a datetime index.
>
>Whereas exact match, >= and BETWEEN are very likely to use an index if there is one. Nobody is so silly as to suggest all these are the same thing AFAICS.
>
>My answer to Dragan was that his example can be achieved by BETWEEN. If you disagree, the question already has been asked how else LIKE might be intended so unless there are examples, I'm not about to be drawn into straw man arguments.
Next time please do read what the thread is about.
OP was saying he couldn't get a match and neither an error. The question was about LIKE is supported or not.
If you have read my previous replies you would see that I am showing LIKE is supported AND also
said that it benefits from an index on the datetime column. But you are (not only you unfortunately) just making assumptions that a datetime (date\datetime2) would go under casting and the index wouldn't be used (That is why I said first check MS SQL insiders).
A LIKE search do benefit from an index on a date\datetime\datetime2\datetimeoffset column.Mind you, you cannot use BETWEEN queries for datetime range searches in MS SQL server.
With a date or datetime2 column, LIKE can be used for searches in the format of yyyy-mm-dd hh:mi:ss.mmm(24h) - this is the ODBC canonical format which clients using ODBC pass in their date\time parameter too.
PS: I am not a native English speaker you know and I hope your "straw man arguments" statement was not an insult on me.