21.2:

```
milovidov-desktop :) SELECT CAST(1111111111.222 AS DateTime64(3))

SELECT cast(1111111111.222, 'DateTime64(3)')

Query id: d10c8623-5c74-4a38-b535-a99f6af4d28d

┌─cast(1111111111.222, 'DateTime64(3)')─┐
│               2005-03-18 04:58:31.222 │
└───────────────────────────────────────┘
```

master:

```
milovidov-desktop :) SELECT CAST(1111111111.222 AS DateTime64(3))

SELECT cast(1111111111.222, 'DateTime64(3)')

Query id: cb4af967-a4ae-4df5-89ba-234d68675f93

┌─cast(1111111111.222, 'DateTime64(3)')─┐
│               2005-03-18 04:58:31.000 │
└───────────────────────────────────────┘
```
auto wrapper_cast_type = cast_type;
        return [wrapper_cast_type, type_index, scale, to_type, requested_result_is_nullable]
            (ColumnsWithTypeAndName & arguments, const DataTypePtr & result_type, const ColumnNullable *column_nullable, size_t input_rows_count)
        {
            ColumnPtr result_column;
            auto res = callOnIndexAndDataType<ToDataType>(type_index, [&](const auto & types) -> bool
            {
                using Types = std::decay_t<decltype(types)>;
                using LeftDataType = typename Types::LeftType;
                using RightDataType = typename Types::RightType;
                if constexpr (IsDataTypeDecimalOrNumber<LeftDataType> && IsDataTypeDecimalOrNumber<RightDataType> && !std::is_same_v<DataTypeDateTime64, RightDataType>)
                {
                    if (wrapper_cast_type == CastType::accurate)
                    {
                        AccurateConvertStrategyAdditions additions;
                        additions.scale = scale;
                        result_column = ConvertImpl<LeftDataType, RightDataType, NameCast>::execute(
                            arguments, result_type, input_rows_count, additions);
                        return true;
                    }
                    else if (wrapper_cast_type == CastType::accurateOrNull)
                    {
                        AccurateOrNullConvertStrategyAdditions additions;
                        additions.scale = scale;
                        result_column = ConvertImpl<LeftDataType, RightDataType, NameCast>::execute(
                            arguments, result_type, input_rows_count, additions);
                        return true;
                    }
                }
                else if constexpr (std::is_same_v<LeftDataType, DataTypeString>)