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

Avatica protobuf: casting to FLOAT data type fails

    XMLWordPrintableJSON

Details

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

    Description

      I have a strange error using Apache Druid avatica protobuf endpoint. I send this query:
       SELECT "user",
      cast("added" as float) m3
      from "wikipedia"
      limit 10
       
      and I get this without a stacktrace:
      ClassCastException: class java.lang.Long cannot be cast to class java.lang.Float (java.lang.Long and java.lang.Float are in module java.base of loader 'bootstrap')

       
      I works with `double` though:
      SELECT
      cast(1.0 as double) m3
      from "wikipedia"
       
      The screenshot shows the exception is thrown here:

      Attachments

        1. image-2023-10-23-13-45-59-828.png
          837 kB
          Egor Ryashin

        Activity

          People

            Unassigned Unassigned
            egrs Egor Ryashin
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: