HappenLee commented on code in PR #64563:
URL: https://github.com/apache/doris/pull/64563#discussion_r3481165177
##########
be/src/exprs/vcolumn_ref.h:
##########
@@ -91,8 +110,45 @@ class VColumnRef final : public VExpr {
double execute_cost() const override { return 0.0; }
private:
+ int _get_column_position(VExprContext* context, const Block* block) const {
+ if (context != nullptr) {
+ const auto resolve_result =
+
context->lambda_execution_context().resolve_column_position(_column_name);
+ if (resolve_result.found) {
+ return resolve_result.column_position;
+ }
+ if (resolve_result.searched_named_scope) {
+ return -1;
+ }
+ }
+ return _get_column_position_without_context(block);
+ }
+
+ int _get_column_position_without_context(const Block* block) const {
+ if (!_gap_set.load()) {
+ const int position_by_name = _find_column_position_by_name(block);
+ if (position_by_name >= 0) {
Review Comment:
如果else的话,不应该是报错吗
--
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]