Uploaded image for project: 'Hive'
  1. Hive
  2. HIVE-12701

select on table with boolean as partition column shows wrong result

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 1.1.0
    • None
    • Database/Schema, SQL
    • None

    Description

      create table hive_aprm02ht7(a int, b int, c int) partitioned by (p boolean) row format delimited fields terminated by ',' stored as textfile;
      
      load data local inpath 'hive_data8.txt' into table hive_aprm02ht7 partition (p=true);
      load data local inpath 'hive_data8.txt' into table hive_aprm02ht7 partition (p=false);
      
      describe hive_aprm02ht7;
      
      col_name        data_type       comment
      a                       int
      b                       int
      c                       int
      p                       boolean
      
      # Partition Information
      # col_name              data_type               comment
      
      p                       boolean
      
      show partitions hive_aprm02ht7;
      
      OK
      p=false
      p=true
      Time taken: 0.057 seconds, Fetched: 2 row(s)
      

      – everything is shown as true. But first three should be true and the last three rows should be false

      hive>  select * from hive_aprm02ht7 where p in (true,false);
      OK
      1       2       3       true
      4       5       6       true
      7       8       9       true
      1       2       3       true
      4       5       6       true
      7       8       9       true
      Time taken: 0.068 seconds, Fetched: 6 row(s)
      

      Attachments

        Activity

          People

            chinnalalam Chinna Rao Lalam
            joysn1980 Joy SN
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: