Uploaded image for project: 'Calcite'
  1. Calcite
  2. CALCITE-2279

Druid adapter duplicate binary expression

    XMLWordPrintableJSON

Details

    Description

      I was looking into Error Prone [1] checking for Calcite and it found what looks like a bug in Druid Adapter. The output is as follows
       

      DruidJsonFilter.java:[324,9] [IdentityBinaryExpression] A binary expression where both operands are the same is usually incorrect; the value of this expression is equivalent to `lhs.getType().getFamily() == SqlTypeFamily.NUMERIC`.
      [ERROR]     (see http://errorprone.info/bugpattern/IdentityBinaryExpression)

       
      The DruidJsonFilter [2] has left and right hand the exact same.
       
      [1] http://errorprone.info/
      [2] https://github.com/apache/calcite/blob/master/druid/src/main/java/org/apache/calcite/adapter/druid/DruidJsonFilter.java#L323

      Attachments

        Issue Links

          Activity

            People

              nishantbangarwa Nishant Bangarwa
              krisden Kevin Risden
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 20m
                  20m