Uploaded image for project: 'Apache Drill'
  1. Apache Drill
  2. DRILL-6401

Precision for decimal data types may be lost for the case when cast with literal is used

Attach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 1.14.0
    • None

    Description

      For the case when cast with decimal literal is used and literal has less precision than specified in the casting type:

      SELECT cast('999.99' as decimal(9, 4)) decimal_9_4
      

      the precision in column metadata is incorrect: 7, but should be 9.

      Test which has the similar check PreparedStatementTest.testQueryMetadataInPreparedStatement is failed when it is ran separately.

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            volodymyr Vova Vysotskyi
            volodymyr Vova Vysotskyi
            Arina Ielchiieva Arina Ielchiieva
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Issue deployment