Issue Details (XML | Word | Printable)

Key: DERBY-83
Type: Improvement Improvement
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Unassigned
Reporter: Jeremy Boynes
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
Derby

Incorrect string conversion for DECIMAL on JDK1.5

Created: 25/Nov/04 11:46 PM   Updated: 20/Mar/07 09:53 PM
Return to search
Component/s: SQL
Affects Version/s: None
Fix Version/s: None

Time Tracking:
Not Specified

File Attachments:
  Size
Text File Licensed for inclusion in ASF works derby_decimal_format.patch 2004-11-25 11:50 PM Jeremy Boynes 3 kB
Environment: JDK1.5

Resolution Date: 29/Nov/04 05:36 PM


 Description  « Hide
On JDK1.5, BigDecimal.toString() will use exponential notation for small values. This results in different text from SQLDecimal.getString() on 1.5 vs. earlier VMs

 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Jeremy Boynes added a comment - 25/Nov/04 11:50 PM
Patch which makes SQLDecimal use BigDecimal.toPlainString() on JDK1.5 so that generated text is the same as in prior versions.

This uses reflection to invoke toPlainString() allowing the code to be compiled on earlier VMs.

Jeremy Boynes made changes - 25/Nov/04 11:50 PM
Field Original Value New Value
Attachment derby_decimal_format.patch [ 18233 ]
Daniel John Debrunner added a comment - 29/Nov/04 05:36 PM
Sending java\engine\org\apache\derby\iapi\services\info\JVMInfo.java
Sending java\engine\org\apache\derby\iapi\types\SQLDecimal.java
Sending java\testing\org\apache\derbyTesting\functionTests\master\floattypes.out
Sending java\testing\org\apache\derbyTesting\functionTests\tests\lang\floattypes.sql
Transmitting file data ....
Committed revision 106931.

Daniel John Debrunner made changes - 29/Nov/04 05:36 PM
Resolution Fixed [ 1 ]
Status Open [ 1 ] Resolved [ 5 ]
Andrew McIntyre made changes - 20/Mar/07 09:53 PM
Status Resolved [ 5 ] Closed [ 6 ]