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

Avatica remote service truncates java.sql.Timestamp to milliseconds

    Details

    • Type: Bug
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None

      Description

      TypedValue in Avatica read/writes java.sql.Timestamp in milliseconds even though natively the type supports nanosecond precision (and Phoenix does use the full precision). The JSON serialization protocol should count with this.

      I'd suggest serializing java.sql.Timestamp with `toString()` and deserializing with `valueOf()` if it's a string. Alternatively, it could be stored as a decimal number or just total number of nanoseconds.

        Attachments

          Activity

            People

            • Assignee:
              julianhyde Julian Hyde
              Reporter:
              lukaslalinsky Lukas Lalinsky
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated: