kangpinghuang commented on a change in pull request #1346: Add column reader
writer for segment V2
URL: https://github.com/apache/incubator-doris/pull/1346#discussion_r296077079
##########
File path: be/src/runtime/vectorized_row_batch.h
##########
@@ -91,10 +93,26 @@ class ColumnVectorView {
return _mem_pool;
}
+ void set_null_bits(size_t num_rows, bool val) {
+ // TODO(zc): use bitmap instead
+ for (int i = 0; i < num_rows; ++i) {
+ _column_vector->is_null()[_row_offset + i] = val;
+ }
+ }
+ bool is_nullable() const {
+ return !_column_vector->no_nulls();
+ }
+
+ uint8_t* data() const {
+ return (uint8_t*)_column_vector->col_data() + _type_info->size() *
_row_offset;
+ }
+
private:
ColumnVector* _column_vector;
size_t _row_offset;
MemPool* _mem_pool;
+ // TODO(zc): move this tho ColumnVector
Review comment:
```suggestion
// TODO(zc): move this to ColumnVector
```
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]