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

PreparedStatement.setObject does not handle Array

    XMLWordPrintableJSON

Details

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

    Description

      Currently setObject() infers the type of the parameter by calling TypedValue.ofJdbc, which delegates to Rep.of(value.getClass()) to do a lookup in VALUE_MAP. VALUE_MAP containsĀ an entry for java.sql.Array, but this is an interface type, which can never match the actual class of avatica.util.ArrayImpl.

      Instead the implementation falls back to OBJECT, which then fails during serialization.

      Attachments

        1. build.gradle
          0.2 kB
          Miles Spielberg
        2. Main.java
          0.6 kB
          Miles Spielberg

        Activity

          People

            Unassigned Unassigned
            mspielberg Miles Spielberg
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: