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

Druid adapter wrongly returns all numeric values as int or float

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.8.0
    • Component/s: None
    • Labels:
      None

      Description

      Druid adapter wrongly returns all numeric values as int or float. If the JDBC driver is expecting long or double, gets a ClassCastException:

      java.lang.ClassCastException: java.lang.Integer cannot be cast to java.lang.Long
      	at org.apache.calcite.avatica.util.AbstractCursor$LongAccessor.getLong(AbstractCursor.java:539)
      	at org.apache.calcite.avatica.util.AbstractCursor$AccessorImpl.getInt(AbstractCursor.java:304)
      	at org.apache.calcite.avatica.AvaticaResultSet.getInt(AvaticaResultSet.java:252)
      	at org.apache.calcite.test.DruidAdapterIT$2.apply(DruidAdapterIT.java:210)
      

        Attachments

          Activity

            People

            • Assignee:
              julianhyde Julian Hyde
              Reporter:
              julianhyde Julian Hyde
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: