morningman commented on code in PR #16677:
URL: https://github.com/apache/doris/pull/16677#discussion_r1105200113


##########
be/src/vec/exec/format/orc/vorc_reader.cpp:
##########
@@ -253,13 +261,25 @@ Status OrcReader::_init_read_columns() {
         
orc_cols_lower_case.emplace_back(_get_field_name_lower_case(&root_type, i));
     }
     for (auto& col_name : _column_names) {
+        if (_is_hive) {
+            auto iter = _scan_params.slot_name_to_schema_pos.find(col_name);
+            if (iter != _scan_params.slot_name_to_schema_pos.end()) {
+                int pos = iter->second;
+                orc_cols_lower_case[pos] = iter->first;
+            }

Review Comment:
   What if `iter == end()`, can it happen? it not, may we should add a DCHECK 
or return error 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: [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]

Reply via email to