Uploaded image for project: 'Apache Drill'
  1. Apache Drill
  2. DRILL-3429

DrillAvgVarianceConvertlet may produce wrong results while rewriting stddev, variance

VotersWatch issueWatchersLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Critical
    • Resolution: Fixed
    • None
    • 1.3.0
    • None
    • None

    Description

      DrillAvgVarianceConvertlet currently rewrites aggregate functions like avg, stddev, variance to simple computations.

      Eg:
      Stddev( x ) => power(
      (sum(x * x) - sum( x ) * sum( x ) / count( x ))
      / count( x ),
      .5)

      Consider the case when the input is an integer. Now the rewrite contains multiplication and division, which will bind to functions that operate on integers however the expected result should be a double and since double has more precision than integer we should be operating on double during the multiplication and division.

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            mehant Mehant Baid
            mehant Mehant Baid
            Victoria Markman Victoria Markman
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment