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

like any is incorrect if contains null

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 3.1.2
    • None
    • Query Planning
    • None

    Description

      How to reproduce:

      CREATE TABLE like_any_table
      STORED AS TEXTFILE
      AS
      SELECT "google" as company,"%oo%" as pat
      UNION ALL
      SELECT "facebook" as company,"%oo%" as pat
      UNION ALL
      SELECT "linkedin" as company,"%in" as pat
      ;
      
      hive> select company from like_any_table where company like any ('%oo%',null);
      OK
      Time taken: 0.064 seconds
      hive> select company from like_any_table where company like '%oo%'  or company like null;
      OK
      google
      facebook
      

      Attachments

        Activity

          People

            Unassigned Unassigned
            yumwang Yuming Wang
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: