try_to_timestamp not working as expected
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-13-2023 03:11 PM
try_to_timestamp should return NULL for following expression but it is throwing error:
try_to_timestamp(
'2019-02-28 23:59:59.000',
'yyyy-MM-dd HH:mm:ss'
)
I understand above expression is wrong as the date format does not confirm to the datetime literal, but I expect a null instead of INCONSISTENT_BEHAVIOR_CROSS_VERSION.PARSE_DATETIME_BY_NEW_PARSER error.