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

Error on Integer and Double modulo or divide by zero

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • None
    • None
    • Backend
    • None

    Description

      In IMPALA-5018, we error on Decimal division by zero. It becomes inconsistent that we return a NULL on Integer divide by zero (instead of returning an error).

      We should also consider returning an error if there is an overflow as a result of mathematical operations on Integers (and maybe Doubles).

      In case of a double division by zero, Impala returns Infinity. We can consider returning an error in this case as well, because this is what Postgres does. In Postgres, modulo does not seem to be even defined for the double type, but we can consider returning an error in case of modulo double zero.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              tarasbob Taras Bobrovytsky
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated: