You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
createtablet (a int);
insert into t values(65535);
altertable t set tiflash replica 1;
set session tidb_isolation_read_engines='tiflash';
select*from t where cast(a as datetime);
# expect empty but get 65535
The text was updated successfully, but these errors were encountered:
The root cause of this bug is that TiFlash doesn't validate the result of cast integer as datetime as strict as TiDB.
This inconsistent behavior only occurs when the original integer value has valid format but doesn't represent a valid datetime value. For example a integer 20210499 can be casted to datetime '2021-04-99', in TiDB it will return NULL while in TiFlash it will return '2021-04-99'.
We can change the severity to major since this is a corner case.
Minimal reproduce:
The text was updated successfully, but these errors were encountered: