You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-dev@db.apache.org by "Knut Anders Hatlen (JIRA)" <ji...@apache.org> on 2007/10/14 16:00:50 UTC

[jira] Commented: (DERBY-3126) Inserting BigDecimal value in PreparedStatement with setBigDecimal into double column loses fractional digits

    [ https://issues.apache.org/jira/browse/DERBY-3126?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12534637 ] 

Knut Anders Hatlen commented on DERBY-3126:
-------------------------------------------

The patch looks correct to me. Two small comments:

  1) There's some strange use of tabs in NetStatementRequest.

  2) I think it would be good to add a test case which tested negative scale. To me it seems like this code assumes that the scale is not negative and not greater than 255:
+                	lidAndLengths[i][1] = (precision << 8) + // use precision above
+                                          (scale << 0);
I know this code was not introduced by you, but I would feel more comfortable if there was a test to verify that it works.

> Inserting BigDecimal value in PreparedStatement with setBigDecimal into double column loses fractional digits
> -------------------------------------------------------------------------------------------------------------
>
>                 Key: DERBY-3126
>                 URL: https://issues.apache.org/jira/browse/DERBY-3126
>             Project: Derby
>          Issue Type: Sub-task
>          Components: JDBC, Network Client
>            Reporter: Kathey Marsden
>         Attachments: derby-2073_diff.txt, derby-2073_diff.txt, derby-2073_stat.txt, derby-2073_stat.txt
>
>
> Splitting this issue into two subtasks one for setBigDecimal and one for setObject as they take a different code path and I plan to submit separate patches. Reproduces with BigDecimalProblemTester attached to DERBY-2073

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.