You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by GitBox <gi...@apache.org> on 2022/07/13 04:01:51 UTC

[GitHub] [doris] HappenLee commented on a diff in pull request #10673: [feature-wip](array-type) explode support more sub types

HappenLee commented on code in PR #10673:
URL: https://github.com/apache/doris/pull/10673#discussion_r919624433


##########
be/src/vec/exprs/table_function/vexplode.cpp:
##########
@@ -56,26 +48,22 @@ Status VExplodeTableFunction::process_row(size_t row_idx) {
     DCHECK(row_idx < _array_column->size());
     _is_current_empty = false;
     _eos = false;
+    _cur_offset = 0;
+    _array_off = (*_detail.offsets_ptr)[row_idx - 1];
+    _cur_size = (*_detail.offsets_ptr)[row_idx] - _array_off;

Review Comment:
   maybe the `_cur_size` should use use `Member variables`
   
   



##########
be/src/vec/exprs/table_function/vexplode.h:
##########
@@ -39,9 +40,9 @@ class VExplodeTableFunction : public TableFunction {
     virtual Status get_value_length(int64_t* length) override;
 
 private:
-    const UInt8* _array_null_map;
-    const ColumnArray* _array_column;
-    size_t _pos;
+    ColumnPtr _array_column;
+    ColumnArrayExecutionData _detail;
+    size_t _array_off; // start offset of array[row_idx]

Review Comment:
   `_array_offset`



-- 
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-unsubscribe@doris.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org