adonis0147 commented on code in PR #9466: URL: https://github.com/apache/incubator-doris/pull/9466#discussion_r873479667
########## be/src/util/array_parser.h: ########## @@ -175,6 +202,37 @@ class ArrayParser { memory_copy(string_val->ptr, iterator->GetString(), iterator->GetStringLength()); break; } + case TYPE_DATE: + case TYPE_DATETIME: { + DateTimeValue value; + value.from_date_str(iterator->GetString(), iterator->GetStringLength()); + *val = reinterpret_cast<AnyVal*>(context->allocate(sizeof(DateTimeVal))); + new (*val) DateTimeVal(); + value.to_datetime_val(static_cast<DateTimeVal*>(*val)); + break; + } + case TYPE_DECIMALV2: { + *val = reinterpret_cast<AnyVal*>(context->allocate(sizeof(DecimalV2Val))); + new (*val) DecimalV2Val(); + + if (iterator->IsNumber()) { + if (iterator->IsInt() || iterator->IsUint() || iterator->IsInt64()) { Review Comment: After refinement, it is sufficient to check whether the iterator is `Uint64` here. -- 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: commits-unsubscr...@doris.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org