[ARRAY] Support array type load and select not include access by index (#5980)
This is part of the array type support and has not been fully completed. The following functions are implemented 1. fe array type support and implementation of array function, support array syntax analysis and planning 2. Support import array type data through insert into 3. Support select array type data 4. Only the array type is supported on the value lie of the duplicate table this pr merge some code from #4655 #4650 #4644 #4643 #4623 #2979
This commit is contained in:
@ -312,6 +312,9 @@ Status Expr::create_expr(ObjectPool* pool, const TExprNode& texpr_node, Expr** e
|
||||
case TExprNodeType::STRING_LITERAL:
|
||||
*expr = pool->add(new Literal(texpr_node));
|
||||
return Status::OK();
|
||||
case TExprNodeType::ARRAY_LITERAL:
|
||||
*expr = pool->add(new Literal(texpr_node));
|
||||
return Status::OK();
|
||||
case TExprNodeType::COMPOUND_PRED:
|
||||
switch (texpr_node.opcode) {
|
||||
case TExprOpcode::COMPOUND_AND:
|
||||
@ -719,6 +722,10 @@ doris_udf::AnyVal* Expr::get_const_val(ExprContext* context) {
|
||||
_constant_val.reset(new AnyVal(true));
|
||||
break;
|
||||
}
|
||||
case TYPE_ARRAY: {
|
||||
_constant_val.reset(new CollectionVal(get_array_val(context, NULL)));
|
||||
break;
|
||||
}
|
||||
default:
|
||||
DCHECK(false) << "Type not implemented: " << type();
|
||||
}
|
||||
@ -797,6 +804,11 @@ DecimalV2Val Expr::get_decimalv2_val(ExprContext* context, TupleRow* row) {
|
||||
return val;
|
||||
}
|
||||
|
||||
CollectionVal Expr::get_array_val(ExprContext* context, TupleRow* row) {
|
||||
CollectionVal val;
|
||||
return val;
|
||||
}
|
||||
|
||||
Status Expr::get_fn_context_error(ExprContext* ctx) {
|
||||
if (_fn_context_index != -1) {
|
||||
FunctionContext* fn_ctx = ctx->fn_context(_fn_context_index);
|
||||
|
||||
Reference in New Issue
Block a user