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


##########
be/src/vec/exec/scan/file_scanner.cpp:
##########
@@ -921,6 +921,22 @@ Status FileScanner::_get_next_reader() {
                 }
             }
         }
+
+        auto compress_type =
+                range.__isset.compress_type ? range.compress_type : 
_params->compress_type;
+
+        if (_params->__isset.file_attributes &&
+            _params->file_attributes.__isset.skip_lines_footer &&
+            _params->file_attributes.skip_lines_footer > 0) {
+            // skip footer lines only supported for uncompressed csv file
+            if (format_type != TFileFormatType::FORMAT_CSV_PLAIN ||
+                (compress_type != TFileCompressType::UNKNOWN &&
+                 compress_type != TFileCompressType::PLAIN)) {
+                return Status::InternalError(

Review Comment:
   Why this is only support for uncompressed data?



##########
be/src/vec/exec/format/csv/csv_reader.cpp:
##########
@@ -277,6 +278,63 @@ void CsvReader::_init_file_description() {
     }
 }
 
+Status CsvReader::_calculate_end_offset_skip_footer_lines(size_t& end_offset) {

Review Comment:
   better use pointer to indicate this is a pass-out parameter



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

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


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

Reply via email to