Uploaded image for project: 'IMPALA'
  1. IMPALA
  2. IMPALA-10447

Missing \n every 1024 or 2048 lines when exporting output from shell to a file

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • Impala 4.0.0
    • Impala 4.0.0
    • Clients
    • None
    • ghx-label-13

    Description

      When Impala shell exports output to a file, for example 

      impala-shell -B  -V  -q "select * from tpcds.item" -o filex.csv --output_delimiter=';'

      then every 1024 (or maybe 2048) rows a newline is missing.

      I think the problem is here: https://github.com/apache/impala/blob/9bb7157bf014282c95ab3e233b80d77e00c95b52/shell/shell_output.py#L119
      where we now use write instead of print to output the rows.
      It may be sufficient to add a

      out_file.write('\n')
      

      here

      Attachments

        Activity

          People

            asherman Andrew Sherman
            asherman Andrew Sherman
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: