Fix parsing of pre-epoch time

This commit is contained in:
Alexey Milovidov 2021-03-15 21:09:05 +03:00
parent badd5165da
commit 845f4afbf4
3 changed files with 3 additions and 6 deletions

View File

@ -913,12 +913,7 @@ public:
if (time_offset >= lut[index].time_at_offset_change())
time_offset -= lut[index].amount_of_offset_change();
UInt32 res = lut[index].date + time_offset;
if (unlikely(res > DATE_LUT_MAX))
return 0;
return res;
return lut[index].date + time_offset;
}
template <typename DateOrTime>

View File

@ -0,0 +1 @@
1925-01-02 03:04:05.678901

View File

@ -0,0 +1 @@
SELECT toDateTime64('1925-01-02 03:04:05.678901', 6);