Uploaded image for project: 'Derby'
  1. Derby
  2. DERBY-2073

Inserting BigDecimal value in PreparedStatement into double column loses fractional digits

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

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 10.1.2.1
    • 10.3.2.1, 10.4.1.3
    • JDBC
    • None
    • windows xp

    Description

      Create table with column of type double.
      Create a prepared statement which inserts value to this column.
      use preparedStatement#setBigDecimal method of the statement to set value of the column.

      Execution of such statement succeeds, but actual value in db has no fractional digits.

      You can use attached test class to reproduce this problem

      Attachments

        Activity

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

          People

            kmarsden Katherine Marsden
            lukaszp Lukasz P
            Votes:
            1 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment