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

Invalid bool value not reported as a scanner error

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Duplicate
    • Affects Version/s: Impala 2.0
    • Fix Version/s: Impala 2.8.0
    • Component/s: Backend
    • Labels:

      Description

      In some cases, reading a bad boolean value does not report a scanner error though the value is NULL, as expected for an invalid value. This is only broken with codegen enabled.

      Here is a query including the tinyint_col so that the row data is shown

      [localhost:21000] > select bool_col, tinyint_col from functional.alltypeserror where id = 30;
      Query: select bool_col, tinyint_col from functional.alltypeserror where id = 30
      +----------+-------------+
      | bool_col | tinyint_col |
      +----------+-------------+
      | NULL     | NULL        |
      +----------+-------------+
      
      ERRORS ENCOUNTERED DURING EXECUTION: 
      Backend 1:Error converting column: 2 TO TINYINT (Data is: err30)
      file: hdfs://localhost:20500/test-warehouse/alltypeserror/year=2009/month=3/0903.txt
      record: 30,t\rue,err30,err30,err30,err300,err30..000000,err300.900000,01/01/10,10,0000-01-01 00:00:00
      
      Returned 1 row(s) in 0.67s
      

      now if only the bool_col is selected there is no error, but there is no valid boolean value in the row data.

      [localhost:21000] > select bool_col from functional.alltypeserror where id = 30;
      Query: select bool_col from functional.alltypeserror where id = 30
      +----------+
      | bool_col |
      +----------+
      | NULL     |
      +----------+
      Returned 1 row(s) in 0.63s
      

      In both cases, there should be an error reported:

      'Error converting column: 1 TO BOOL (Data is: t\rue)'

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                sailesh Sailesh Mukil
                Reporter:
                mjacobs Matthew Jacobs
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: