zhangstar333 commented on code in PR #61396:
URL: https://github.com/apache/doris/pull/61396#discussion_r2957341320
##########
be/src/core/data_type_serde/data_type_datetimev2_serde.cpp:
##########
@@ -355,12 +355,24 @@ Status
DataTypeDateTimeV2SerDe::write_column_to_arrow(const IColumn& column,
DateV2Value<DateTimeV2ValueType> datetime_val = col_data[i];
datetime_val.unix_timestamp(×tamp, real_ctz);
- if (_scale > 3) {
+ switch (timestamp_type->unit()) {
+ case arrow::TimeUnit::NANO: {
uint32_t microsecond = datetime_val.microsecond();
- timestamp = (timestamp * 1000000) + microsecond;
- } else if (_scale > 0) {
+ timestamp = (timestamp * 1000000000LL) + (microsecond *
1000LL);
Review Comment:
here overflow of int64 when datetime is 9999-12-31
need some time to find soultion
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]