CachedRowSetImpl#updateObject has useless call to BigDecimal.setScale

XMLWordPrintable

    • Type: Bug
    • Resolution: Unresolved
    • Priority: P4
    • tbd
    • Affects Version/s: 8
    • Component/s: core-libs
    • None

      As found by errorprone, this code:

              if (type == Types.DECIMAL || type == Types.NUMERIC) {
                  ((java.math.BigDecimal)x).setScale(scale);
              }

      has no effect because setScale is a pure function. Probably you want to assign that back to x. Probably tests should be written.

            Assignee:
            Lance Andersen
            Reporter:
            Martin Buchholz
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: