When I tried to convert `string` to `timestamp` with `to_timestamp()` function, I got some unexpected NULL values . So I am writing this issue to seek for your help.
Currently, the built-in function `to_timestamp()` return NULL when input's length is not equal to the length of format string describes. For example, the following query returns `NULL`:
While this query returns converted value:
Snippet below explains the relative logic. The file name is `cast-functions-ir.cc`
Will it be better if function accepts the shorter input and returns converted timestamp with some padding zeros? i.e. returns 2020-01-01 18:00:00.012000000 with the following sql